Add osmtogeojson

This commit is contained in:
tkqubo
2016-01-08 11:52:57 +09:00
parent 939bf16689
commit 811fc834c7
+3 -1
View File
@@ -1,9 +1,11 @@
/// <reference path="osmtogeojson.d.ts" />
/// <reference path="../xmldom/xmldom.d.ts" />
import osmtogeojson from 'osmtogeojson';
import {OsmJSON, GeoJSON} from 'osmtogeojson';
import * as xmldom from 'xmldom';
let xml: Document = (new DOMParser()).parseFromString("<osm><node id='1' lat='1.234' lon='4.321' /></osm>", 'text/xml');
let xml: Document = (new xmldom.DOMParser()).parseFromString("<osm><node id='1' lat='1.234' lon='4.321' /></osm>", 'text/xml');
let geojson: GeoJSON.FeatureCollection = {
type: "FeatureCollection",
features: [