Coder Social home page Coder Social logo

dpmcmlxxvi / olturf Goto Github PK

View Code? Open in Web Editor NEW
31.0 5.0 10.0 4.01 MB

A Turf toolbar for OpenLayers.

Home Page: https://dpmcmlxxvi.github.io/olturf/

License: MIT License

JavaScript 94.61% CSS 4.22% HTML 1.17%
openlayers turf toolbar javascript geospatial gis algorithm ol3-turf

olturf's Introduction

OpenLayers Turf

build coverage codacy npm

OpenLayers Turf (olturf) is a Turf toolbar for OpenLayers. The toolbar provides the following features:

  • Customizable commands to display
  • Forms to collect command inputs
  • Popups to display numerical outputs
  • Input features are selected in the map
  • Output features are displayed in the map

Instead of displaying all the Turf commands available, individual commands can be selected or a subset of pre-defined groups can be displayed. The following groups are available aggregation, classification, data, grids, interpolation, measurement, misc, joins, transformation.

GETTING STARTED

A toolbar can be added to an OpenLayers map by adding its dependencies

<link href="https://cdn.rawgit.com/openlayers/openlayers.github.io/master/en/v5.3.0/css/ol.css"
  rel="stylesheet" type="text/css" />
<link href="https://unpkg.com/olturf/dist/olturf.min.css" rel="stylesheet" type="text/css" />

<script src="https://cdn.rawgit.com/openlayers/openlayers.github.io/master/en/v5.3.0/build/ol.js"></script>
<script src="https://unpkg.com/@turf/[email protected]/turf.min.js"></script>
<script src="https://unpkg.com/olturf/dist/olturf.min.js"></script>

then creating an instance and adding it to the map

const toolbar = new olturf.Toolbar();
const map = new ol.Map({...});
map.addControl(toolbar);

DOCUMENTATION

The following help is available at the olturf website:

BUILD

To build and test the library locally:

npm install
npm test

The bundled library and stylesheet are at dist/olturf.min.js and dist/olturf.min.css.

LICENSE

Copyright (c) 2016 Daniel Pulido mailto:[email protected]

Source code is released under the MIT License. Documentation is released under the CC BY 4.0. Icons are from OSGeo and released under the CC BY 3.0.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.