Example to ilustrate this question at gis.stackoverflow.
We choose to replace Turf with JSTS.
If the result is more complex (i.e. the resulting intersection is a polyline), the algorithm should be repeated for each part in the polygon.
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Leaflet with D3 popups</title> | |
<meta charset="utf-8" /> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3/4.13.0/d3.min.js"></script> | |
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.3.1/dist/leaflet.css" integrity="sha512-Rksm5RenBEKSKFjgI3a41vrjkw4EVPlJ3+OiI65vTjIdo9brlAacEuKOiQ5OFh7cOI1bkDwLqdLw3Zg0cRJAAQ==" crossorigin=""/> | |
<script src="https://unpkg.com/leaflet@1.3.1/dist/leaflet.js" integrity="sha512-/Nsx9X4HebavoBvEBuyp3I7od5tA0UzAxs+j83KgC8PU0kgB4XiK4Lfe4y4cgBtaRJQEIFCW+oC506aPT2L1zw==" crossorigin=""></script> |
Example to ilustrate this question at gis.stackoverflow.
We choose to replace Turf with JSTS.
If the result is more complex (i.e. the resulting intersection is a polyline), the algorithm should be repeated for each part in the polygon.
This simple line chart is constructed from a TSV file storing the closing value of AAPL stock over the last few years. The chart employs conventional margins and a number of D3 features:
This also uses simple-statistics to derive a linear regression of the price changes.
This GIST provides an example of a Google Maps map with an OL3 map as control, to give users a Google base map with OL3 content on top.
Open the corresponding bl.ock to view the example in your browser.
<?php | |
header('Content-Type: application/json; charset=UTF-8'); | |
/** | |
* PostGIS to GeoJSON | |
* Query a PostGIS table or view and return the results in GeoJSON format, suitable for use in OpenLayers, Leaflet, etc. | |
* | |
* @param string $geotable The PostGIS layer name *REQUIRED* | |
* @param string $geomfield The PostGIS geometry field *REQUIRED* | |
* @param string $srid The SRID of the returned GeoJSON *OPTIONAL (If omitted, EPSG: 4326 will be used)* | |
* @param string $fields Fields to be returned *OPTIONAL (If omitted, all fields will be returned)* NOTE- Uppercase field names should be wrapped in double quotes |
/node_modules/ | |
bundle.js |
An example of LeafletJS using OpenStreetMap tiles and the Markers API (use the same API signature as Mapbox Markers API). You can define your own marker styles using the options outlined in simplestyle-spec, including all Maki icons.
OpenLayers.Layer.D3 = OpenLayers.Class(OpenLayers.Layer.Vector, { | |
d3FeaturesNodeClass:'d3features', | |
d3Features:[], | |
afterAdd:function(){ | |
var self = this; | |
if(this.renderer.CLASS_NAME.match(/SVG$/)){ | |
this.d3InitSVG(); | |
this.events.register('moveend',this,this.onMoveEnd); |
hg clone https://bitbucket.org/tiax/bitbucket-issues-cli # Fork repo with support for Git on Bitbucket | |
cd bitbucket-issues-cli | |
hg patch ../patch-bitbucket-issues-cli-1 |
height: 600 |