mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-12-03 03:31:47 +00:00
Restructured the files and added missing json configurations
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
/// <reference path="../leaflet/leaflet.d.ts" />
|
||||
/// <reference path="leaflet.heat.d.ts" />
|
||||
|
||||
var osmUrl = 'http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png',
|
||||
/// <reference path="index.d.ts" />
|
||||
const osmUrl = 'http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png',
|
||||
osmAttrib = '© <a href="http://openstreetmap.org/copyright">OpenStreetMap</a> contributors',
|
||||
osm = L.tileLayer(osmUrl, {maxZoom: 18, attribution: osmAttrib}),
|
||||
map = new L.Map('map', {
|
||||
@@ -11,7 +10,7 @@ var osmUrl = 'http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png',
|
||||
});
|
||||
|
||||
// Each point in the input array can be either an array like [50.5, 30.5, 0.5], or a Leaflet LatLng object.
|
||||
var heat: L.HeatLayer = L.heatLayer([
|
||||
const heat: L.HeatLayer = L.heatLayer([
|
||||
[50.5, 30.5, 0.2], // lat, lng, intensity
|
||||
[50.6, 30.4, 0.5],
|
||||
new L.LatLng(50.7, 30.3),
|
||||
@@ -28,7 +27,7 @@ heat.setOptions({
|
||||
});
|
||||
|
||||
// Add new point to heat layer
|
||||
var newLatLng = new L.LatLng(50.8, 30.2);
|
||||
const newLatLng = new L.LatLng(50.8, 30.2);
|
||||
heat.addLatLng(newLatLng);
|
||||
|
||||
// Set new latLng list to the heat layer
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6",
|
||||
"dom"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"leaflet.heat-tests.ts"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Reference in New Issue
Block a user