styled-map-package 4.1.0 → 5.0.0-pre.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (238) hide show
  1. package/README.md +47 -7
  2. package/bin/smp-download.js +27 -151
  3. package/bin/smp-mbtiles.js +12 -7
  4. package/bin/smp-view.js +32 -54
  5. package/lib/commands/download.js +188 -0
  6. package/lib/commands/mbtiles.js +21 -0
  7. package/lib/commands/view.js +57 -0
  8. package/lib/reporters.js +92 -0
  9. package/package.json +9 -181
  10. package/LICENSE.md +0 -7
  11. package/dist/download.cjs +0 -101
  12. package/dist/download.d.cts +0 -65
  13. package/dist/download.d.ts +0 -65
  14. package/dist/download.js +0 -77
  15. package/dist/from-mbtiles.cjs +0 -91
  16. package/dist/from-mbtiles.d.cts +0 -17
  17. package/dist/from-mbtiles.d.ts +0 -17
  18. package/dist/from-mbtiles.js +0 -57
  19. package/dist/index.cjs +0 -49
  20. package/dist/index.d.cts +0 -27
  21. package/dist/index.d.ts +0 -27
  22. package/dist/index.js +0 -18
  23. package/dist/reader-watch.cjs +0 -135
  24. package/dist/reader-watch.d.cts +0 -24
  25. package/dist/reader-watch.d.ts +0 -24
  26. package/dist/reader-watch.js +0 -101
  27. package/dist/reader.cjs +0 -168
  28. package/dist/reader.d.cts +0 -62
  29. package/dist/reader.d.ts +0 -62
  30. package/dist/reader.js +0 -139
  31. package/dist/reporters.cjs +0 -122
  32. package/dist/reporters.d.cts +0 -10
  33. package/dist/reporters.d.ts +0 -10
  34. package/dist/reporters.js +0 -88
  35. package/dist/server.cjs +0 -78
  36. package/dist/server.d.cts +0 -48
  37. package/dist/server.d.ts +0 -48
  38. package/dist/server.js +0 -54
  39. package/dist/style-downloader.cjs +0 -312
  40. package/dist/style-downloader.d.cts +0 -120
  41. package/dist/style-downloader.d.ts +0 -120
  42. package/dist/style-downloader.js +0 -288
  43. package/dist/tile-downloader.cjs +0 -158
  44. package/dist/tile-downloader.d.cts +0 -84
  45. package/dist/tile-downloader.d.ts +0 -84
  46. package/dist/tile-downloader.js +0 -126
  47. package/dist/types-yLQy3AKR.d.cts +0 -192
  48. package/dist/types-yLQy3AKR.d.ts +0 -192
  49. package/dist/utils/errors.cjs +0 -41
  50. package/dist/utils/errors.d.cts +0 -18
  51. package/dist/utils/errors.d.ts +0 -18
  52. package/dist/utils/errors.js +0 -16
  53. package/dist/utils/fetch.cjs +0 -96
  54. package/dist/utils/fetch.d.cts +0 -51
  55. package/dist/utils/fetch.d.ts +0 -51
  56. package/dist/utils/fetch.js +0 -62
  57. package/dist/utils/file-formats.cjs +0 -98
  58. package/dist/utils/file-formats.d.cts +0 -35
  59. package/dist/utils/file-formats.d.ts +0 -35
  60. package/dist/utils/file-formats.js +0 -62
  61. package/dist/utils/geo.cjs +0 -84
  62. package/dist/utils/geo.d.cts +0 -46
  63. package/dist/utils/geo.d.ts +0 -46
  64. package/dist/utils/geo.js +0 -56
  65. package/dist/utils/mapbox.cjs +0 -121
  66. package/dist/utils/mapbox.d.cts +0 -43
  67. package/dist/utils/mapbox.d.ts +0 -43
  68. package/dist/utils/mapbox.js +0 -91
  69. package/dist/utils/misc.cjs +0 -39
  70. package/dist/utils/misc.d.cts +0 -22
  71. package/dist/utils/misc.d.ts +0 -22
  72. package/dist/utils/misc.js +0 -13
  73. package/dist/utils/streams.cjs +0 -130
  74. package/dist/utils/streams.d.cts +0 -73
  75. package/dist/utils/streams.d.ts +0 -73
  76. package/dist/utils/streams.js +0 -103
  77. package/dist/utils/style.cjs +0 -126
  78. package/dist/utils/style.d.cts +0 -69
  79. package/dist/utils/style.d.ts +0 -69
  80. package/dist/utils/style.js +0 -98
  81. package/dist/utils/templates.cjs +0 -118
  82. package/dist/utils/templates.d.cts +0 -80
  83. package/dist/utils/templates.d.ts +0 -80
  84. package/dist/utils/templates.js +0 -81
  85. package/dist/writer.cjs +0 -449
  86. package/dist/writer.d.cts +0 -7
  87. package/dist/writer.d.ts +0 -7
  88. package/dist/writer.js +0 -424
  89. package/node_modules/@node-rs/crc32/LICENSE +0 -21
  90. package/node_modules/@node-rs/crc32/README.md +0 -61
  91. package/node_modules/@node-rs/crc32/browser.js +0 -1
  92. package/node_modules/@node-rs/crc32/index.d.ts +0 -5
  93. package/node_modules/@node-rs/crc32/index.js +0 -368
  94. package/node_modules/@node-rs/crc32/package.json +0 -97
  95. package/node_modules/@node-rs/crc32-linux-x64-gnu/README.md +0 -3
  96. package/node_modules/@node-rs/crc32-linux-x64-gnu/crc32.linux-x64-gnu.node +0 -0
  97. package/node_modules/@node-rs/crc32-linux-x64-gnu/package.json +0 -43
  98. package/node_modules/@node-rs/crc32-linux-x64-musl/README.md +0 -3
  99. package/node_modules/@node-rs/crc32-linux-x64-musl/crc32.linux-x64-musl.node +0 -0
  100. package/node_modules/@node-rs/crc32-linux-x64-musl/package.json +0 -43
  101. package/node_modules/define-data-property/.eslintrc +0 -24
  102. package/node_modules/define-data-property/.github/FUNDING.yml +0 -12
  103. package/node_modules/define-data-property/.nycrc +0 -13
  104. package/node_modules/define-data-property/CHANGELOG.md +0 -70
  105. package/node_modules/define-data-property/LICENSE +0 -21
  106. package/node_modules/define-data-property/README.md +0 -67
  107. package/node_modules/define-data-property/index.d.ts +0 -12
  108. package/node_modules/define-data-property/index.js +0 -56
  109. package/node_modules/define-data-property/package.json +0 -106
  110. package/node_modules/define-data-property/test/index.js +0 -392
  111. package/node_modules/define-data-property/tsconfig.json +0 -59
  112. package/node_modules/define-properties/.editorconfig +0 -13
  113. package/node_modules/define-properties/.eslintrc +0 -19
  114. package/node_modules/define-properties/.github/FUNDING.yml +0 -12
  115. package/node_modules/define-properties/.nycrc +0 -9
  116. package/node_modules/define-properties/CHANGELOG.md +0 -91
  117. package/node_modules/define-properties/LICENSE +0 -21
  118. package/node_modules/define-properties/README.md +0 -84
  119. package/node_modules/define-properties/index.js +0 -47
  120. package/node_modules/define-properties/package.json +0 -88
  121. package/node_modules/es-define-property/.eslintrc +0 -13
  122. package/node_modules/es-define-property/.github/FUNDING.yml +0 -12
  123. package/node_modules/es-define-property/.nycrc +0 -9
  124. package/node_modules/es-define-property/CHANGELOG.md +0 -29
  125. package/node_modules/es-define-property/LICENSE +0 -21
  126. package/node_modules/es-define-property/README.md +0 -49
  127. package/node_modules/es-define-property/index.d.ts +0 -3
  128. package/node_modules/es-define-property/index.js +0 -14
  129. package/node_modules/es-define-property/package.json +0 -81
  130. package/node_modules/es-define-property/test/index.js +0 -56
  131. package/node_modules/es-define-property/tsconfig.json +0 -10
  132. package/node_modules/es-errors/.eslintrc +0 -5
  133. package/node_modules/es-errors/.github/FUNDING.yml +0 -12
  134. package/node_modules/es-errors/CHANGELOG.md +0 -40
  135. package/node_modules/es-errors/LICENSE +0 -21
  136. package/node_modules/es-errors/README.md +0 -55
  137. package/node_modules/es-errors/eval.d.ts +0 -3
  138. package/node_modules/es-errors/eval.js +0 -4
  139. package/node_modules/es-errors/index.d.ts +0 -3
  140. package/node_modules/es-errors/index.js +0 -4
  141. package/node_modules/es-errors/package.json +0 -80
  142. package/node_modules/es-errors/range.d.ts +0 -3
  143. package/node_modules/es-errors/range.js +0 -4
  144. package/node_modules/es-errors/ref.d.ts +0 -3
  145. package/node_modules/es-errors/ref.js +0 -4
  146. package/node_modules/es-errors/syntax.d.ts +0 -3
  147. package/node_modules/es-errors/syntax.js +0 -4
  148. package/node_modules/es-errors/test/index.js +0 -19
  149. package/node_modules/es-errors/tsconfig.json +0 -49
  150. package/node_modules/es-errors/type.d.ts +0 -3
  151. package/node_modules/es-errors/type.js +0 -4
  152. package/node_modules/es-errors/uri.d.ts +0 -3
  153. package/node_modules/es-errors/uri.js +0 -4
  154. package/node_modules/globalthis/.eslintrc +0 -18
  155. package/node_modules/globalthis/.nycrc +0 -10
  156. package/node_modules/globalthis/CHANGELOG.md +0 -109
  157. package/node_modules/globalthis/LICENSE +0 -21
  158. package/node_modules/globalthis/README.md +0 -70
  159. package/node_modules/globalthis/auto.js +0 -3
  160. package/node_modules/globalthis/implementation.browser.js +0 -11
  161. package/node_modules/globalthis/implementation.js +0 -3
  162. package/node_modules/globalthis/index.js +0 -19
  163. package/node_modules/globalthis/package.json +0 -99
  164. package/node_modules/globalthis/polyfill.js +0 -10
  165. package/node_modules/globalthis/shim.js +0 -29
  166. package/node_modules/globalthis/test/implementation.js +0 -11
  167. package/node_modules/globalthis/test/index.js +0 -11
  168. package/node_modules/globalthis/test/native.js +0 -26
  169. package/node_modules/globalthis/test/shimmed.js +0 -29
  170. package/node_modules/globalthis/test/tests.js +0 -36
  171. package/node_modules/gopd/.eslintrc +0 -16
  172. package/node_modules/gopd/.github/FUNDING.yml +0 -12
  173. package/node_modules/gopd/CHANGELOG.md +0 -45
  174. package/node_modules/gopd/LICENSE +0 -21
  175. package/node_modules/gopd/README.md +0 -40
  176. package/node_modules/gopd/gOPD.d.ts +0 -1
  177. package/node_modules/gopd/gOPD.js +0 -4
  178. package/node_modules/gopd/index.d.ts +0 -5
  179. package/node_modules/gopd/index.js +0 -15
  180. package/node_modules/gopd/package.json +0 -77
  181. package/node_modules/gopd/test/index.js +0 -36
  182. package/node_modules/gopd/tsconfig.json +0 -9
  183. package/node_modules/has-property-descriptors/.eslintrc +0 -13
  184. package/node_modules/has-property-descriptors/.github/FUNDING.yml +0 -12
  185. package/node_modules/has-property-descriptors/.nycrc +0 -9
  186. package/node_modules/has-property-descriptors/CHANGELOG.md +0 -35
  187. package/node_modules/has-property-descriptors/LICENSE +0 -21
  188. package/node_modules/has-property-descriptors/README.md +0 -43
  189. package/node_modules/has-property-descriptors/index.js +0 -22
  190. package/node_modules/has-property-descriptors/package.json +0 -77
  191. package/node_modules/has-property-descriptors/test/index.js +0 -57
  192. package/node_modules/is-it-type/License +0 -19
  193. package/node_modules/is-it-type/README.md +0 -102
  194. package/node_modules/is-it-type/changelog.md +0 -239
  195. package/node_modules/is-it-type/dist/cjs/is-it-type.js +0 -173
  196. package/node_modules/is-it-type/dist/cjs/is-it-type.js.map +0 -1
  197. package/node_modules/is-it-type/dist/cjs/is-it-type.min.js +0 -2
  198. package/node_modules/is-it-type/dist/cjs/is-it-type.min.js.map +0 -1
  199. package/node_modules/is-it-type/dist/esm/is-it-type.js +0 -143
  200. package/node_modules/is-it-type/dist/esm/is-it-type.js.map +0 -1
  201. package/node_modules/is-it-type/dist/esm/is-it-type.min.js +0 -2
  202. package/node_modules/is-it-type/dist/esm/is-it-type.min.js.map +0 -1
  203. package/node_modules/is-it-type/dist/esm/package.json +0 -3
  204. package/node_modules/is-it-type/dist/umd/is-it-type.js +0 -450
  205. package/node_modules/is-it-type/dist/umd/is-it-type.js.map +0 -1
  206. package/node_modules/is-it-type/dist/umd/is-it-type.min.js +0 -2
  207. package/node_modules/is-it-type/dist/umd/is-it-type.min.js.map +0 -1
  208. package/node_modules/is-it-type/es/index.js +0 -8
  209. package/node_modules/is-it-type/es/package.json +0 -3
  210. package/node_modules/is-it-type/index.js +0 -10
  211. package/node_modules/is-it-type/package.json +0 -87
  212. package/node_modules/is-it-type/src/index.js +0 -169
  213. package/node_modules/object-keys/.editorconfig +0 -13
  214. package/node_modules/object-keys/.eslintrc +0 -17
  215. package/node_modules/object-keys/.travis.yml +0 -277
  216. package/node_modules/object-keys/CHANGELOG.md +0 -232
  217. package/node_modules/object-keys/LICENSE +0 -21
  218. package/node_modules/object-keys/README.md +0 -76
  219. package/node_modules/object-keys/implementation.js +0 -122
  220. package/node_modules/object-keys/index.js +0 -32
  221. package/node_modules/object-keys/isArguments.js +0 -17
  222. package/node_modules/object-keys/package.json +0 -88
  223. package/node_modules/object-keys/test/index.js +0 -5
  224. package/node_modules/simple-invariant/License +0 -19
  225. package/node_modules/simple-invariant/README.md +0 -64
  226. package/node_modules/simple-invariant/changelog.md +0 -31
  227. package/node_modules/simple-invariant/index.js +0 -19
  228. package/node_modules/simple-invariant/package.json +0 -50
  229. package/node_modules/yauzl-promise/License +0 -19
  230. package/node_modules/yauzl-promise/README.md +0 -440
  231. package/node_modules/yauzl-promise/index.js +0 -10
  232. package/node_modules/yauzl-promise/lib/entry.js +0 -312
  233. package/node_modules/yauzl-promise/lib/index.js +0 -160
  234. package/node_modules/yauzl-promise/lib/reader.js +0 -289
  235. package/node_modules/yauzl-promise/lib/shared.js +0 -20
  236. package/node_modules/yauzl-promise/lib/utils.js +0 -105
  237. package/node_modules/yauzl-promise/lib/zip.js +0 -1224
  238. package/node_modules/yauzl-promise/package.json +0 -56
@@ -1,40 +0,0 @@
1
- # gopd <sup>[![Version Badge][npm-version-svg]][package-url]</sup>
2
-
3
- [![github actions][actions-image]][actions-url]
4
- [![coverage][codecov-image]][codecov-url]
5
- [![License][license-image]][license-url]
6
- [![Downloads][downloads-image]][downloads-url]
7
-
8
- [![npm badge][npm-badge-png]][package-url]
9
-
10
- `Object.getOwnPropertyDescriptor`, but accounts for IE's broken implementation.
11
-
12
- ## Usage
13
-
14
- ```javascript
15
- var gOPD = require('gopd');
16
- var assert = require('assert');
17
-
18
- if (gOPD) {
19
- assert.equal(typeof gOPD, 'function', 'descriptors supported');
20
- // use gOPD like Object.getOwnPropertyDescriptor here
21
- } else {
22
- assert.ok(!gOPD, 'descriptors not supported');
23
- }
24
- ```
25
-
26
- [package-url]: https://npmjs.org/package/gopd
27
- [npm-version-svg]: https://versionbadg.es/ljharb/gopd.svg
28
- [deps-svg]: https://david-dm.org/ljharb/gopd.svg
29
- [deps-url]: https://david-dm.org/ljharb/gopd
30
- [dev-deps-svg]: https://david-dm.org/ljharb/gopd/dev-status.svg
31
- [dev-deps-url]: https://david-dm.org/ljharb/gopd#info=devDependencies
32
- [npm-badge-png]: https://nodei.co/npm/gopd.png?downloads=true&stars=true
33
- [license-image]: https://img.shields.io/npm/l/gopd.svg
34
- [license-url]: LICENSE
35
- [downloads-image]: https://img.shields.io/npm/dm/gopd.svg
36
- [downloads-url]: https://npm-stat.com/charts.html?package=gopd
37
- [codecov-image]: https://codecov.io/gh/ljharb/gopd/branch/main/graphs/badge.svg
38
- [codecov-url]: https://app.codecov.io/gh/ljharb/gopd/
39
- [actions-image]: https://img.shields.io/endpoint?url=https://github-actions-badge-u3jn4tfpocch.runkit.sh/ljharb/gopd
40
- [actions-url]: https://github.com/ljharb/gopd/actions
@@ -1 +0,0 @@
1
- export = Object.getOwnPropertyDescriptor;
@@ -1,4 +0,0 @@
1
- 'use strict';
2
-
3
- /** @type {import('./gOPD')} */
4
- module.exports = Object.getOwnPropertyDescriptor;
@@ -1,5 +0,0 @@
1
- declare function gOPD<O extends object, K extends keyof O>(obj: O, prop: K): PropertyDescriptor | undefined;
2
-
3
- declare const fn: typeof gOPD | undefined | null;
4
-
5
- export = fn;
@@ -1,15 +0,0 @@
1
- 'use strict';
2
-
3
- /** @type {import('.')} */
4
- var $gOPD = require('./gOPD');
5
-
6
- if ($gOPD) {
7
- try {
8
- $gOPD([], 'length');
9
- } catch (e) {
10
- // IE 8 has a broken gOPD
11
- $gOPD = null;
12
- }
13
- }
14
-
15
- module.exports = $gOPD;
@@ -1,77 +0,0 @@
1
- {
2
- "name": "gopd",
3
- "version": "1.2.0",
4
- "description": "`Object.getOwnPropertyDescriptor`, but accounts for IE's broken implementation.",
5
- "main": "index.js",
6
- "exports": {
7
- ".": "./index.js",
8
- "./gOPD": "./gOPD.js",
9
- "./package.json": "./package.json"
10
- },
11
- "sideEffects": false,
12
- "scripts": {
13
- "prepack": "npmignore --auto --commentLines=autogenerated",
14
- "prepublishOnly": "safe-publish-latest",
15
- "prepublish": "not-in-publish || npm run prepublishOnly",
16
- "prelint": "tsc -p . && attw -P",
17
- "lint": "eslint --ext=js,mjs .",
18
- "postlint": "evalmd README.md",
19
- "pretest": "npm run lint",
20
- "tests-only": "tape 'test/**/*.js'",
21
- "test": "npm run tests-only",
22
- "posttest": "npx npm@'>=10.2' audit --production",
23
- "version": "auto-changelog && git add CHANGELOG.md",
24
- "postversion": "auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""
25
- },
26
- "repository": {
27
- "type": "git",
28
- "url": "git+https://github.com/ljharb/gopd.git"
29
- },
30
- "keywords": [
31
- "ecmascript",
32
- "javascript",
33
- "getownpropertydescriptor",
34
- "property",
35
- "descriptor"
36
- ],
37
- "author": "Jordan Harband <ljharb@gmail.com>",
38
- "funding": {
39
- "url": "https://github.com/sponsors/ljharb"
40
- },
41
- "license": "MIT",
42
- "bugs": {
43
- "url": "https://github.com/ljharb/gopd/issues"
44
- },
45
- "homepage": "https://github.com/ljharb/gopd#readme",
46
- "devDependencies": {
47
- "@arethetypeswrong/cli": "^0.17.0",
48
- "@ljharb/eslint-config": "^21.1.1",
49
- "@ljharb/tsconfig": "^0.2.0",
50
- "@types/tape": "^5.6.5",
51
- "auto-changelog": "^2.5.0",
52
- "encoding": "^0.1.13",
53
- "eslint": "=8.8.0",
54
- "evalmd": "^0.0.19",
55
- "in-publish": "^2.0.1",
56
- "npmignore": "^0.3.1",
57
- "safe-publish-latest": "^2.0.0",
58
- "tape": "^5.9.0",
59
- "typescript": "next"
60
- },
61
- "auto-changelog": {
62
- "output": "CHANGELOG.md",
63
- "template": "keepachangelog",
64
- "unreleased": false,
65
- "commitLimit": false,
66
- "backfillLimit": false,
67
- "hideCredit": true
68
- },
69
- "publishConfig": {
70
- "ignore": [
71
- ".github/workflows"
72
- ]
73
- },
74
- "engines": {
75
- "node": ">= 0.4"
76
- }
77
- }
@@ -1,36 +0,0 @@
1
- 'use strict';
2
-
3
- var test = require('tape');
4
- var gOPD = require('../');
5
-
6
- test('gOPD', function (t) {
7
- t.test('supported', { skip: !gOPD }, function (st) {
8
- st.equal(typeof gOPD, 'function', 'is a function');
9
-
10
- var obj = { x: 1 };
11
- st.ok('x' in obj, 'property exists');
12
-
13
- // @ts-expect-error TS can't figure out narrowing from `skip`
14
- var desc = gOPD(obj, 'x');
15
- st.deepEqual(
16
- desc,
17
- {
18
- configurable: true,
19
- enumerable: true,
20
- value: 1,
21
- writable: true
22
- },
23
- 'descriptor is as expected'
24
- );
25
-
26
- st.end();
27
- });
28
-
29
- t.test('not supported', { skip: !!gOPD }, function (st) {
30
- st.notOk(gOPD, 'is falsy');
31
-
32
- st.end();
33
- });
34
-
35
- t.end();
36
- });
@@ -1,9 +0,0 @@
1
- {
2
- "extends": "@ljharb/tsconfig",
3
- "compilerOptions": {
4
- "target": "es2021",
5
- },
6
- "exclude": [
7
- "coverage",
8
- ],
9
- }
@@ -1,13 +0,0 @@
1
- {
2
- "root": true,
3
-
4
- "extends": "@ljharb",
5
-
6
- "rules": {
7
- "func-name-matching": 0,
8
- "id-length": 0,
9
- "new-cap": [2, {
10
- "capIsNewExceptions": ["GetIntrinsic"],
11
- }],
12
- },
13
- }
@@ -1,12 +0,0 @@
1
- # These are supported funding model platforms
2
-
3
- github: [ljharb]
4
- patreon: # Replace with a single Patreon username
5
- open_collective: # Replace with a single Open Collective username
6
- ko_fi: # Replace with a single Ko-fi username
7
- tidelift: npm/has-property-descriptors
8
- community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9
- liberapay: # Replace with a single Liberapay username
10
- issuehunt: # Replace with a single IssueHunt username
11
- otechie: # Replace with a single Otechie username
12
- custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
@@ -1,9 +0,0 @@
1
- {
2
- "all": true,
3
- "check-coverage": false,
4
- "reporter": ["text-summary", "text", "html", "json"],
5
- "exclude": [
6
- "coverage",
7
- "test"
8
- ]
9
- }
@@ -1,35 +0,0 @@
1
- # Changelog
2
-
3
- All notable changes to this project will be documented in this file.
4
-
5
- The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
6
- and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
-
8
- ## [v1.0.2](https://github.com/inspect-js/has-property-descriptors/compare/v1.0.1...v1.0.2) - 2024-02-12
9
-
10
- ### Commits
11
-
12
- - [Refactor] use `es-define-property` [`f93a8c8`](https://github.com/inspect-js/has-property-descriptors/commit/f93a8c85eba70cbceab500f2619fb5cce73a1805)
13
- - [Dev Deps] update `aud`, `npmignore`, `tape` [`42b0c9d`](https://github.com/inspect-js/has-property-descriptors/commit/42b0c9d1c23e747755f0f2924923c418ea34a9ee)
14
- - [Deps] update `get-intrinsic` [`35e9b46`](https://github.com/inspect-js/has-property-descriptors/commit/35e9b46a7f14331bf0de98b644dd803676746037)
15
-
16
- ## [v1.0.1](https://github.com/inspect-js/has-property-descriptors/compare/v1.0.0...v1.0.1) - 2023-10-20
17
-
18
- ### Commits
19
-
20
- - [meta] use `npmignore` to autogenerate an npmignore file [`5bbf4da`](https://github.com/inspect-js/has-property-descriptors/commit/5bbf4dae1b58950d87bb3af508bee7513e640868)
21
- - [actions] update rebase action to use reusable workflow [`3a5585b`](https://github.com/inspect-js/has-property-descriptors/commit/3a5585bf74988f71a8f59e67a07d594e62c51fd8)
22
- - [Dev Deps] update `@ljharb/eslint-config`, `aud`, `tape` [`e5c1212`](https://github.com/inspect-js/has-property-descriptors/commit/e5c1212048a8fda549794c47863724ca60b89cae)
23
- - [Dev Deps] update `aud`, `tape` [`e942917`](https://github.com/inspect-js/has-property-descriptors/commit/e942917b6c2f7c090d5623048989cf20d0834ebf)
24
- - [Deps] update `get-intrinsic` [`f4a44ec`](https://github.com/inspect-js/has-property-descriptors/commit/f4a44ec6d94146fa6c550d3c15c31a2062c83ef4)
25
- - [Deps] update `get-intrinsic` [`eeb275b`](https://github.com/inspect-js/has-property-descriptors/commit/eeb275b473e5d72ca843b61ca25cfcb06a5d4300)
26
-
27
- ## v1.0.0 - 2022-04-14
28
-
29
- ### Commits
30
-
31
- - Initial implementation, tests [`303559f`](https://github.com/inspect-js/has-property-descriptors/commit/303559f2a72dfe7111573a1aec475ed4a184c35a)
32
- - Initial commit [`3a7ca2d`](https://github.com/inspect-js/has-property-descriptors/commit/3a7ca2dc49f1fff0279a28bb16265e7615e14749)
33
- - read me [`dd73dce`](https://github.com/inspect-js/has-property-descriptors/commit/dd73dce09d89d0f7a4a6e3b1e562a506f979a767)
34
- - npm init [`c1e6557`](https://github.com/inspect-js/has-property-descriptors/commit/c1e655779de632d68cb944c50da6b71bcb7b8c85)
35
- - Only apps should have lockfiles [`e72f7c6`](https://github.com/inspect-js/has-property-descriptors/commit/e72f7c68de534b2d273ee665f8b18d4ecc7f70b0)
@@ -1,21 +0,0 @@
1
- MIT License
2
-
3
- Copyright (c) 2022 Inspect JS
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
@@ -1,43 +0,0 @@
1
- # has-property-descriptors <sup>[![Version Badge][npm-version-svg]][package-url]</sup>
2
-
3
- [![github actions][actions-image]][actions-url]
4
- [![coverage][codecov-image]][codecov-url]
5
- [![dependency status][deps-svg]][deps-url]
6
- [![dev dependency status][dev-deps-svg]][dev-deps-url]
7
- [![License][license-image]][license-url]
8
- [![Downloads][downloads-image]][downloads-url]
9
-
10
- [![npm badge][npm-badge-png]][package-url]
11
-
12
- Does the environment have full property descriptor support? Handles IE 8's broken defineProperty/gOPD.
13
-
14
- ## Example
15
-
16
- ```js
17
- var hasPropertyDescriptors = require('has-property-descriptors');
18
- var assert = require('assert');
19
-
20
- assert.equal(hasPropertyDescriptors(), true); // will be `false` in IE 6-8, and ES5 engines
21
-
22
- // Arrays can not have their length `[[Defined]]` in some engines
23
- assert.equal(hasPropertyDescriptors.hasArrayLengthDefineBug(), false); // will be `true` in Firefox 4-22, and node v0.6
24
- ```
25
-
26
- ## Tests
27
- Simply clone the repo, `npm install`, and run `npm test`
28
-
29
- [package-url]: https://npmjs.org/package/has-property-descriptors
30
- [npm-version-svg]: https://versionbadg.es/inspect-js/has-property-descriptors.svg
31
- [deps-svg]: https://david-dm.org/inspect-js/has-property-descriptors.svg
32
- [deps-url]: https://david-dm.org/inspect-js/has-property-descriptors
33
- [dev-deps-svg]: https://david-dm.org/inspect-js/has-property-descriptors/dev-status.svg
34
- [dev-deps-url]: https://david-dm.org/inspect-js/has-property-descriptors#info=devDependencies
35
- [npm-badge-png]: https://nodei.co/npm/has-property-descriptors.png?downloads=true&stars=true
36
- [license-image]: https://img.shields.io/npm/l/has-property-descriptors.svg
37
- [license-url]: LICENSE
38
- [downloads-image]: https://img.shields.io/npm/dm/has-property-descriptors.svg
39
- [downloads-url]: https://npm-stat.com/charts.html?package=has-property-descriptors
40
- [codecov-image]: https://codecov.io/gh/inspect-js/has-property-descriptors/branch/main/graphs/badge.svg
41
- [codecov-url]: https://app.codecov.io/gh/inspect-js/has-property-descriptors/
42
- [actions-image]: https://img.shields.io/endpoint?url=https://github-actions-badge-u3jn4tfpocch.runkit.sh/inspect-js/has-property-descriptors
43
- [actions-url]: https://github.com/inspect-js/has-property-descriptors/actions
@@ -1,22 +0,0 @@
1
- 'use strict';
2
-
3
- var $defineProperty = require('es-define-property');
4
-
5
- var hasPropertyDescriptors = function hasPropertyDescriptors() {
6
- return !!$defineProperty;
7
- };
8
-
9
- hasPropertyDescriptors.hasArrayLengthDefineBug = function hasArrayLengthDefineBug() {
10
- // node v0.6 has a bug where array lengths can be Set but not Defined
11
- if (!$defineProperty) {
12
- return null;
13
- }
14
- try {
15
- return $defineProperty([], 'length', { value: 1 }).length !== 1;
16
- } catch (e) {
17
- // In Firefox 4-22, defining length on an array throws an exception.
18
- return true;
19
- }
20
- };
21
-
22
- module.exports = hasPropertyDescriptors;
@@ -1,77 +0,0 @@
1
- {
2
- "name": "has-property-descriptors",
3
- "version": "1.0.2",
4
- "description": "Does the environment have full property descriptor support? Handles IE 8's broken defineProperty/gOPD.",
5
- "main": "index.js",
6
- "exports": {
7
- ".": "./index.js",
8
- "./package.json": "./package.json"
9
- },
10
- "sideEffects": false,
11
- "scripts": {
12
- "prepack": "npmignore --auto --commentLines=autogenerated",
13
- "prepublishOnly": "safe-publish-latest",
14
- "prepublish": "not-in-publish || npm run prepublishOnly",
15
- "pretest": "npm run lint",
16
- "prelint": "evalmd README.md",
17
- "lint": "eslint --ext=js,mjs .",
18
- "tests-only": "nyc tape 'test/**/*.js'",
19
- "test": "npm run tests-only",
20
- "posttest": "aud --production",
21
- "version": "auto-changelog && git add CHANGELOG.md",
22
- "postversion": "auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""
23
- },
24
- "repository": {
25
- "type": "git",
26
- "url": "git+https://github.com/inspect-js/has-property-descriptors.git"
27
- },
28
- "keywords": [
29
- "property",
30
- "descriptors",
31
- "has",
32
- "environment",
33
- "env",
34
- "defineProperty",
35
- "getOwnPropertyDescriptor"
36
- ],
37
- "author": "Jordan Harband <ljharb@gmail.com>",
38
- "funding": {
39
- "url": "https://github.com/sponsors/ljharb"
40
- },
41
- "license": "MIT",
42
- "bugs": {
43
- "url": "https://github.com/inspect-js/has-property-descriptors/issues"
44
- },
45
- "homepage": "https://github.com/inspect-js/has-property-descriptors#readme",
46
- "devDependencies": {
47
- "@ljharb/eslint-config": "^21.1.0",
48
- "aud": "^2.0.4",
49
- "auto-changelog": "^2.4.0",
50
- "eslint": "=8.8.0",
51
- "evalmd": "^0.0.19",
52
- "in-publish": "^2.0.1",
53
- "npmignore": "^0.3.1",
54
- "nyc": "^10.3.2",
55
- "safe-publish-latest": "^2.0.0",
56
- "tape": "^5.7.4"
57
- },
58
- "dependencies": {
59
- "es-define-property": "^1.0.0"
60
- },
61
- "testling": {
62
- "files": "test/index.js"
63
- },
64
- "auto-changelog": {
65
- "output": "CHANGELOG.md",
66
- "template": "keepachangelog",
67
- "unreleased": false,
68
- "commitLimit": false,
69
- "backfillLimit": false,
70
- "hideCredit": true
71
- },
72
- "publishConfig": {
73
- "ignore": [
74
- ".github/workflows"
75
- ]
76
- }
77
- }
@@ -1,57 +0,0 @@
1
- 'use strict';
2
-
3
- var test = require('tape');
4
-
5
- var hasPropertyDescriptors = require('../');
6
-
7
- var sentinel = {};
8
-
9
- test('hasPropertyDescriptors', function (t) {
10
- t.equal(typeof hasPropertyDescriptors, 'function', 'is a function');
11
- t.equal(typeof hasPropertyDescriptors.hasArrayLengthDefineBug, 'function', '`hasArrayLengthDefineBug` property is a function');
12
-
13
- var yes = hasPropertyDescriptors();
14
- t.test('property descriptors', { skip: !yes }, function (st) {
15
- var o = { a: sentinel };
16
-
17
- st.deepEqual(
18
- Object.getOwnPropertyDescriptor(o, 'a'),
19
- {
20
- configurable: true,
21
- enumerable: true,
22
- value: sentinel,
23
- writable: true
24
- },
25
- 'has expected property descriptor'
26
- );
27
-
28
- Object.defineProperty(o, 'a', { enumerable: false, writable: false });
29
-
30
- st.deepEqual(
31
- Object.getOwnPropertyDescriptor(o, 'a'),
32
- {
33
- configurable: true,
34
- enumerable: false,
35
- value: sentinel,
36
- writable: false
37
- },
38
- 'has expected property descriptor after [[Define]]'
39
- );
40
-
41
- st.end();
42
- });
43
-
44
- var arrayBug = hasPropertyDescriptors.hasArrayLengthDefineBug();
45
- t.test('defining array lengths', { skip: !yes || arrayBug }, function (st) {
46
- var arr = [1, , 3]; // eslint-disable-line no-sparse-arrays
47
- st.equal(arr.length, 3, 'array starts with length 3');
48
-
49
- Object.defineProperty(arr, 'length', { value: 5 });
50
-
51
- st.equal(arr.length, 5, 'array ends with length 5');
52
-
53
- st.end();
54
- });
55
-
56
- t.end();
57
- });
@@ -1,19 +0,0 @@
1
- Copyright (c) 2022 Overlook Motel (theoverlookmotel@gmail.com)
2
-
3
- Permission is hereby granted, free of charge, to any person obtaining a copy
4
- of this software and associated documentation files (the "Software"), to deal
5
- in the Software without restriction, including without limitation the rights
6
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7
- copies of the Software, and to permit persons to whom the Software is
8
- furnished to do so, subject to the following conditions:
9
-
10
- The above copyright notice and this permission notice shall be included in
11
- all copies or substantial portions of the Software.
12
-
13
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19
- THE SOFTWARE.
@@ -1,102 +0,0 @@
1
- [![NPM version](https://img.shields.io/npm/v/is-it-type.svg)](https://www.npmjs.com/package/is-it-type)
2
- [![Build Status](https://img.shields.io/github/workflow/status/overlookmotel/is-it-type/Test.svg)](https://github.com/overlookmotel/is-it-type/actions)
3
- [![Dependency Status](https://img.shields.io/david/overlookmotel/is-it-type.svg)](https://david-dm.org/overlookmotel/is-it-type)
4
- [![Dev dependency Status](https://img.shields.io/david/dev/overlookmotel/is-it-type.svg)](https://david-dm.org/overlookmotel/is-it-type)
5
- [![Coverage Status](https://img.shields.io/coveralls/overlookmotel/is-it-type/master.svg)](https://coveralls.io/r/overlookmotel/is-it-type)
6
-
7
- # Determine type of a variable
8
-
9
- All the functions from [core-util-is](https://www.npmjs.com/package/core-util-is) plus a few extras, in both CJS and ESM formats for use in Node.js or browser.
10
-
11
- ## Usage
12
-
13
- ### Import
14
-
15
- ```js
16
- const { isString } = require('is-it-type');
17
- ```
18
-
19
- or:
20
-
21
- ```js
22
- import { isString } from 'is-it-type';
23
- ```
24
-
25
- ### Use a method
26
-
27
- ```js
28
- isString('abc'); // true
29
- ```
30
-
31
- All methods return `true` or `false`.
32
-
33
- ## Methods
34
-
35
- ### Same as [core-util-is](https://www.npmjs.com/package/core-util-is):
36
-
37
- * `isArray`
38
- * `isBoolean`
39
- * `isNull`
40
- * `isNullOrUndefined`
41
- * `isNumber`
42
- * `isString`
43
- * `isSymbol`
44
- * `isUndefined`
45
- * `isRegExp`
46
- * `isDate`
47
- * `isError`
48
- * `isFunction`
49
- * `isPrimitive`
50
-
51
- NB [core-util-is](https://www.npmjs.com/package/core-util-is)'s `isBuffer` is not included. `isObject` method differs from [core-util-is](https://www.npmjs.com/package/core-util-is)'s method of same name (see [below](#objects)).
52
-
53
- ### Additional functions
54
-
55
- #### Strings
56
-
57
- * `isEmptyString` - `true` if `=== ''`
58
- * `isFullString` - `true` if a string which `!== ''`
59
-
60
- #### Numbers
61
-
62
- * `isInteger` - `true` if is an integer number (positive, negative or zero)
63
- * `isPositiveInteger` - `true` if is an integer number > 0
64
- * `isPositiveIntegerOrZero` - `true` if is an integer number >= 0
65
- * `isNegativeInteger` - `true` if is an integer number < 0
66
- * `isNegativeIntegerOrZero` - `true` if is an integer number <= 0
67
-
68
- #### Objects
69
-
70
- * `isObject` - `true` if passed object (not including arrays, regexps and other built-ins)
71
- * `isEmptyObject` - `true` if passed object with no properties
72
-
73
- #### Other
74
-
75
- * `isType( type, input )` - `true` if `typeof input === type`
76
-
77
- ## Versioning
78
-
79
- This module follows [semver](https://semver.org/). Breaking changes will only be made in major version updates.
80
-
81
- All active NodeJS release lines are supported (v12+ at time of writing). After a release line of NodeJS reaches end of life according to [Node's LTS schedule](https://nodejs.org/en/about/releases/), support for that version of Node may be dropped at any time, and this will not be considered a breaking change. Dropping support for a Node version will be made in a minor version update (e.g. 1.2.0 to 1.3.0). If you are using a Node version which is approaching end of life, pin your dependency of this module to patch updates only using tilde (`~`) e.g. `~1.2.3` to avoid breakages.
82
-
83
- ## Tests
84
-
85
- Use `npm test` to run the tests. Use `npm run cover` to check coverage.
86
-
87
- ## Changelog
88
-
89
- See [changelog.md](https://github.com/overlookmotel/is-it-type/blob/master/changelog.md)
90
-
91
- ## Issues
92
-
93
- If you discover a bug, please raise an issue on Github. https://github.com/overlookmotel/is-it-type/issues
94
-
95
- ## Contribution
96
-
97
- Pull requests are very welcome. Please:
98
-
99
- * ensure all tests pass before submitting PR
100
- * add tests for new features
101
- * document new functionality/API additions in README
102
- * do not add an entry to Changelog (Changelog is created when cutting releases)