Commit Graph

75 Commits

Author SHA1 Message Date
Tim Schaub 054af09032 Make code prettier
This updates ESLint and our shared eslint-config-openlayers to use Prettier.  Most formatting changes were automatically applied with this:

    npm run lint -- --fix

A few manual changes were required:

 * In `examples/offscreen-canvas.js`, the `//eslint-disable-line` comment needed to be moved to the appropriate line to disable the error about the `'worker-loader!./offscreen-canvas.worker.js'` import.
 * In `examples/webpack/exapmle-builder.js`, spaces could not be added after a couple `function`s for some reason.  While editing this, I reworked `ExampleBuilder` to be a class.
 * In `src/ol/format/WMSGetFeatureInfo.js`, the `// @ts-ignore` comment needed to be moved down one line so it applied to the `parsersNS` argument.
2020-04-06 12:54:09 -06:00
Andreas Hocevar ac50cc3460 New eslint config with no-multi-assign 2019-11-02 15:20:21 +01:00
Tim Schaub e9a30c5cb7 Use standard tile coords 2018-11-21 11:14:17 -07:00
Tim Schaub ccfacc5ee6 Transformed types
Using the [ts.js codemod](https://gist.github.com/tschaub/1ea498c9d1e5268cf36d212b3949be4e):

    jscodeshift --transform ts.js src
2018-09-05 08:05:29 -06:00
Tim Schaub d12ef20b12 Use Array<Foo> instead of Array.<Foo> 2018-07-25 18:32:43 -07:00
ahocevar 440d1ad3e1 Shorter module paths for default exports 2018-04-25 17:25:39 +02:00
ahocevar e383913b3c Fix some type paths 2018-03-17 13:34:57 +01:00
Andreas Hocevar 95d6251dbb Get rid of olx.js and typedef.js typedefs for ol 2018-03-08 18:57:24 +01:00
Marc Jansen 685b46f1e3 Named exports from tilecoord 2018-02-15 18:04:51 +01:00
Tim Schaub ad62739a6e Use blocked scoped variables
In addition to using const and let, this also upgrades our linter config and removes lint (mostly whitespace).
2018-01-12 00:50:30 -07:00
Ron Young a11208d126 rename _ol_math_ imports 2017-12-20 19:31:00 -06:00
Frederic Junod 9349ba5403 Named export for ol/asserts 2017-12-18 10:33:41 +01:00
Frederic Junod 3cc63c4767 Named export for ol/tileurlfunction
And change module name from ol/TileUrlFunction to ol/tileurlfunction
2017-12-17 18:32:43 +01:00
Tim Schaub 1cdb6a66f0 Imports cased like the filename 2017-12-12 06:53:17 -07:00
Marc Jansen 7d6929c710 Manual adjustment of indentation 2017-06-20 10:41:03 +02:00
Marc Jansen d0ef05977b Autofix indentation issues (eslint --fix) 2017-06-19 11:58:00 +02:00
Frederic Junod 5763e1d145 Remove unused goog.require 2017-02-03 12:40:53 +01:00
Tim Schaub 137cdc04c8 Remove ol.DEBUG 2017-01-01 20:37:52 -07:00
Frederic Junod 2591f61fd3 Allow more than one digit range in ol.TileUrlFunction.expandUrl
To be able to have number range like `{9-13}`
2016-09-15 08:44:22 +02:00
Marc Jansen 5afd5c838e Require ol in ol.tileurlfunction 2016-09-02 11:20:49 +02:00
Andreas Hocevar d1e4b33760 Rename goog.DEBUG to ol.DEBUG 2016-08-31 21:10:01 +02:00
Tim Schaub 274b7285f3 Assorted missing requires 2016-08-12 10:53:48 -06:00
Tim Schaub d02cf1e7a9 Shuffle assertions 2016-08-12 10:53:47 -06:00
Andreas Hocevar e18d41b5e0 Remove gratuitous debug assertions 2016-08-04 11:29:54 +02:00
Andreas Hocevar e0015b3d4e Use goog.DEBUG instead of ol.DEBUG for now 2016-08-04 11:29:54 +02:00
Andreas Hocevar 6f5ed17fc5 Remove goog.asserts.*
This pull requests replaces type check hint assertions with type casts,
library sanity check assertions with conditional console.assert statements
in debug mode, and runtime sanity checks with assertions that throw an
ol.AssertionError with an error code for lookup outside the library.
2016-08-04 11:29:54 +02:00
Peter Robins 535e8f5e35 Move top-level typedefs to typedefs.js
With one exception, those directly in the `ol` namespace can be moved without problem.
Some left-over goog.requires are also removed.
2016-05-11 17:18:05 +00:00
Peter Robins f57065c412 Remove unneeded goog.provides/requires for typedefs
In general, typedefs do not need and should not have goog.require/provide
2016-05-09 13:21:25 +00:00
Peter Robins 51397ee294 Remove unused ol.TileCoordTransformType 2016-05-07 10:35:11 +00:00
Nicholas Latham 2ee1969de7 Remove goog.math.modulo and goog.math.lerp 2016-04-04 09:43:24 +02:00
Tim Schaub 3cf8618fc7 Prefer single line assignment to 80 character limit 2016-01-11 18:56:08 -08:00
Marc Jansen ef0153692e Remove goog.isNull in tileurlfunction class 2015-10-01 09:18:53 +02:00
Andreas Hocevar 8248ec63ba Fix {-y} template calculation for custom (TMS) tile grids
Previously, {-y} only worked for the standard web mercator tile grid. Now
a tile grid with an extent is required (which we get from
ol.tilegrid.createXYZ() anyway), and then the y calculation for TMS style
tile grids works as expected.
2015-09-30 09:07:55 +02:00
Frederic Junod 9e2a393426 Remove use of goog.array.map 2015-09-29 10:54:55 +02:00
Andreas Hocevar af319c259b Do not transform tile coordinates for tileUrlFunction 2015-06-19 18:34:09 +02:00
Andreas Hocevar 6a4d1c9b89 Pass transformed tile coordinates to the tileUrlFunction 2015-06-12 09:45:03 +02:00
Andreas Hocevar 4196e34c73 Improve doucmentation for ol.TileUrlFunctionType 2015-05-28 18:52:35 +02:00
Éric Lemoine 2a2fea379e Add ol.source.WMTS#getUrls 2015-04-27 16:40:01 +02:00
Éric Lemoine ba035abb1f Change ol.TileCoord to an Array 2014-08-18 09:33:24 +02:00
Andreas Hocevar 08039e9894 Replace multiple placeholder occurrences in templates 2014-08-07 10:51:41 +02:00
Tim Schaub 4cf5ab4620 Use @api annotation instead of @todo api 2014-07-05 15:41:14 -04:00
Andreas Hocevar fbdbbfb7a7 Get rid of stability annotations and document stability with api
This change adds a stability value to the api annotation, with
'experimental' as default value.

enum, typedef and event annotations are never exportable, but
api annotations are needed there to make them appear in the
docs.

Nested typedefs are no longer inlined recursively, because the
resulting tables get too wide with the current template.
2014-04-29 09:53:07 -06:00
Frederic Junod 9b5512c065 Allow '{-y}' placeholder 2014-04-14 14:27:18 +02:00
Tom Payne a31ad69ec4 Make tile URL functions more general 2014-04-03 15:12:22 +02:00
Bart van den Eijnden 87d651af04 Add documentation for API typedef functions 2014-02-14 15:32:12 +01:00
Tom Payne 33f0024747 Add pixelRatio to ol.TileUrlFunction 2014-01-15 15:53:46 +01:00
Tom Payne 807bf757af Remove unused ol.TileUrlFunction.createFromParamsFunction 2014-01-09 15:27:56 +01:00
Tom Payne 784f3500f2 Make ol.extent.buffer return an extent instead of mutating 2014-01-09 15:27:56 +01:00
Tom Payne 46267a9059 Use toString() instead of + '' 2014-01-03 14:55:02 +01:00
Éric Lemoine e14d8add85 Add gutter support to TileUrlFunction 2013-12-12 10:59:31 +01:00