From 4ae3cdcbe20995304eee3f3d0562dd9f144e2259 Mon Sep 17 00:00:00 2001 From: Justin Fagnani Date: Tue, 8 Jan 2019 18:31:07 -0800 Subject: [PATCH] Support new decorators proposal as implemented in Babel 7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Moves @property tests to decorators_test.ts * Adds a Babel build step to compile decorators_test.ts to decorators-babel_test.js * Updates decorators to detect if they’re called in legacy or modern decorator mode Fixes #156 --- .babelrc | 6 + package-lock.json | 1074 ++++++++++++++++++++++++++++--- package.json | 7 +- src/env.d.ts | 16 + src/lib/decorators.ts | 106 ++- src/test/lib/decorators_test.ts | 196 +++++- src/test/lit-element_test.ts | 191 ------ test/runner.html | 1 + 8 files changed, 1284 insertions(+), 313 deletions(-) create mode 100644 .babelrc diff --git a/.babelrc b/.babelrc new file mode 100644 index 00000000..91523d14 --- /dev/null +++ b/.babelrc @@ -0,0 +1,6 @@ +{ + "plugins":[ + ["@babel/plugin-proposal-decorators", {"decoratorsBeforeExport": true}], + "@babel/plugin-proposal-class-properties", + "@babel/plugin-transform-typescript"] +} diff --git a/package-lock.json b/package-lock.json index 23b5df88..397cf69c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4,6 +4,32 @@ "lockfileVersion": 1, "requires": true, "dependencies": { + "@babel/cli": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/@babel/cli/-/cli-7.2.3.tgz", + "integrity": "sha512-bfna97nmJV6nDJhXNPeEfxyMjWnt6+IjUAaDPiYRTBlm8L41n8nvw6UAqUCbvpFfU246gHPxW7sfWwqtF4FcYA==", + "dev": true, + "requires": { + "chokidar": "^2.0.3", + "commander": "^2.8.1", + "convert-source-map": "^1.1.0", + "fs-readdir-recursive": "^1.1.0", + "glob": "^7.0.0", + "lodash": "^4.17.10", + "mkdirp": "^0.5.1", + "output-file-sync": "^2.0.0", + "slash": "^2.0.0", + "source-map": "^0.5.0" + }, + "dependencies": { + "source-map": { + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", + "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", + "dev": true + } + } + }, "@babel/code-frame": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.0.0.tgz", @@ -109,6 +135,116 @@ "@babel/types": "^7.0.0" } }, + "@babel/helper-create-class-features-plugin": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.2.3.tgz", + "integrity": "sha512-xO/3Gn+2C7/eOUeb0VRnSP1+yvWHNxlpAot1eMhtoKDCN7POsyQP5excuT5UsV5daHxMWBeIIOeI5cmB8vMRgQ==", + "dev": true, + "requires": { + "@babel/helper-function-name": "^7.1.0", + "@babel/helper-member-expression-to-functions": "^7.0.0", + "@babel/helper-optimise-call-expression": "^7.0.0", + "@babel/helper-plugin-utils": "^7.0.0", + "@babel/helper-replace-supers": "^7.2.3" + }, + "dependencies": { + "@babel/generator": { + "version": "7.2.2", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.2.2.tgz", + "integrity": "sha512-I4o675J/iS8k+P38dvJ3IBGqObLXyQLTxtrR4u9cSUJOURvafeEWb/pFMOTwtNrmq73mJzyF6ueTbO1BtN0Zeg==", + "dev": true, + "requires": { + "@babel/types": "^7.2.2", + "jsesc": "^2.5.1", + "lodash": "^4.17.10", + "source-map": "^0.5.0", + "trim-right": "^1.0.1" + }, + "dependencies": { + "@babel/types": { + "version": "7.2.2", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.2.2.tgz", + "integrity": "sha512-fKCuD6UFUMkR541eDWL+2ih/xFZBXPOg/7EQFeTluMDebfqR4jrpaCjLhkWlQS4hT6nRa2PMEgXKbRB5/H2fpg==", + "dev": true, + "requires": { + "esutils": "^2.0.2", + "lodash": "^4.17.10", + "to-fast-properties": "^2.0.0" + } + } + } + }, + "@babel/helper-replace-supers": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.2.3.tgz", + "integrity": "sha512-GyieIznGUfPXPWu0yLS6U55Mz67AZD9cUk0BfirOWlPrXlBcan9Gz+vHGz+cPfuoweZSnPzPIm67VtQM0OWZbA==", + "dev": true, + "requires": { + "@babel/helper-member-expression-to-functions": "^7.0.0", + "@babel/helper-optimise-call-expression": "^7.0.0", + "@babel/traverse": "^7.2.3", + "@babel/types": "^7.0.0" + } + }, + "@babel/parser": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.2.3.tgz", + "integrity": "sha512-0LyEcVlfCoFmci8mXx8A5oIkpkOgyo8dRHtxBnK9RRBwxO2+JZPNsqtVEZQ7mJFPxnXF9lfmU24mHOPI0qnlkA==", + "dev": true + }, + "@babel/traverse": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.2.3.tgz", + "integrity": "sha512-Z31oUD/fJvEWVR0lNZtfgvVt512ForCTNKYcJBGbPb1QZfve4WGH8Wsy7+Mev33/45fhP/hwQtvgusNdcCMgSw==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.0.0", + "@babel/generator": "^7.2.2", + "@babel/helper-function-name": "^7.1.0", + "@babel/helper-split-export-declaration": "^7.0.0", + "@babel/parser": "^7.2.3", + "@babel/types": "^7.2.2", + "debug": "^4.1.0", + "globals": "^11.1.0", + "lodash": "^4.17.10" + }, + "dependencies": { + "@babel/types": { + "version": "7.2.2", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.2.2.tgz", + "integrity": "sha512-fKCuD6UFUMkR541eDWL+2ih/xFZBXPOg/7EQFeTluMDebfqR4jrpaCjLhkWlQS4hT6nRa2PMEgXKbRB5/H2fpg==", + "dev": true, + "requires": { + "esutils": "^2.0.2", + "lodash": "^4.17.10", + "to-fast-properties": "^2.0.0" + } + } + } + }, + "debug": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", + "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", + "dev": true, + "requires": { + "ms": "^2.1.1" + } + }, + "ms": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", + "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==", + "dev": true + }, + "source-map": { + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", + "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", + "dev": true + } + } + }, "@babel/helper-define-map": { "version": "7.1.0", "resolved": "https://registry.npmjs.org/@babel/helper-define-map/-/helper-define-map-7.1.0.tgz", @@ -319,6 +455,27 @@ "@babel/plugin-syntax-async-generators": "^7.0.0" } }, + "@babel/plugin-proposal-class-properties": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.2.3.tgz", + "integrity": "sha512-FVuQngLoN2iDrpW7LmhPZ2sO4DJxf35FOcwidwB9Ru9tMvI5URthnkVHuG14IStV+TzkMTyLMoOUlSTtrdVwqw==", + "dev": true, + "requires": { + "@babel/helper-create-class-features-plugin": "^7.2.3", + "@babel/helper-plugin-utils": "^7.0.0" + } + }, + "@babel/plugin-proposal-decorators": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-decorators/-/plugin-proposal-decorators-7.2.3.tgz", + "integrity": "sha512-jhCFm7ftmue02EWIYqbhzP0iConEPsgVQeDriOs/Qc2lgr6MDtHTTrv3hE2GOOQDFjQ9tjP7nWQq0ad0JhIsQg==", + "dev": true, + "requires": { + "@babel/helper-create-class-features-plugin": "^7.2.3", + "@babel/helper-plugin-utils": "^7.0.0", + "@babel/plugin-syntax-decorators": "^7.2.0" + } + }, "@babel/plugin-proposal-object-rest-spread": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.0.0.tgz", @@ -338,6 +495,15 @@ "@babel/helper-plugin-utils": "^7.0.0" } }, + "@babel/plugin-syntax-decorators": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-decorators/-/plugin-syntax-decorators-7.2.0.tgz", + "integrity": "sha512-38QdqVoXdHUQfTpZo3rQwqQdWtCn5tMv4uV6r2RMfTqNBuv4ZBhz79SfaQWKTVmxHjeFv/DnXVC/+agHCklYWA==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.0.0" + } + }, "@babel/plugin-syntax-dynamic-import": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.0.0.tgz", @@ -365,6 +531,15 @@ "@babel/helper-plugin-utils": "^7.0.0" } }, + "@babel/plugin-syntax-typescript": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.2.0.tgz", + "integrity": "sha512-WhKr6yu6yGpGcNMVgIBuI9MkredpVc7Y3YR4UzEZmDztHoL6wV56YBHLhWnjO1EvId1B32HrD3DRFc+zSoKI1g==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.0.0" + } + }, "@babel/plugin-transform-arrow-functions": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.0.0.tgz", @@ -581,6 +756,16 @@ "@babel/helper-plugin-utils": "^7.0.0" } }, + "@babel/plugin-transform-typescript": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.2.0.tgz", + "integrity": "sha512-EnI7i2/gJ7ZNr2MuyvN2Hu+BHJENlxWte5XygPvfj/MbvtOkWor9zcnHpMMQL2YYaaCcqtIvJUyJ7QVfoGs7ew==", + "dev": true, + "requires": { + "@babel/helper-plugin-utils": "^7.0.0", + "@babel/plugin-syntax-typescript": "^7.2.0" + } + }, "@babel/plugin-transform-unicode-regex": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.0.0.tgz", @@ -738,19 +923,19 @@ }, "@types/clean-css": { "version": "3.4.30", - "resolved": "https://registry.npmjs.org/@types/clean-css/-/clean-css-3.4.30.tgz", + "resolved": "http://registry.npmjs.org/@types/clean-css/-/clean-css-3.4.30.tgz", "integrity": "sha1-AFLBNvUkgAJCjjY4s33ko5gYZB0=", "dev": true }, "@types/clone": { "version": "0.1.30", - "resolved": "https://registry.npmjs.org/@types/clone/-/clone-0.1.30.tgz", + "resolved": "http://registry.npmjs.org/@types/clone/-/clone-0.1.30.tgz", "integrity": "sha1-5zZWSMG0ITalnH1QQGN7O1yDthQ=", "dev": true }, "@types/compression": { "version": "0.0.33", - "resolved": "https://registry.npmjs.org/@types/compression/-/compression-0.0.33.tgz", + "resolved": "http://registry.npmjs.org/@types/compression/-/compression-0.0.33.tgz", "integrity": "sha1-ldxzOiM5qoRjgdfxN3eS0lU9wn0=", "dev": true, "requires": { @@ -774,13 +959,13 @@ }, "@types/cssbeautify": { "version": "0.3.1", - "resolved": "https://registry.npmjs.org/@types/cssbeautify/-/cssbeautify-0.3.1.tgz", + "resolved": "http://registry.npmjs.org/@types/cssbeautify/-/cssbeautify-0.3.1.tgz", "integrity": "sha1-jgvuj33suVIlDaDK6+BeMFkcF+8=", "dev": true }, "@types/doctrine": { "version": "0.0.1", - "resolved": "https://registry.npmjs.org/@types/doctrine/-/doctrine-0.0.1.tgz", + "resolved": "http://registry.npmjs.org/@types/doctrine/-/doctrine-0.0.1.tgz", "integrity": "sha1-uZny2fe0PKvgoaLzm8IDvH3K2p0=", "dev": true }, @@ -798,7 +983,7 @@ }, "@types/events": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@types/events/-/events-1.2.0.tgz", + "resolved": "http://registry.npmjs.org/@types/events/-/events-1.2.0.tgz", "integrity": "sha512-KEIlhXnIutzKwRbQkGWb/I4HFqBuUykAdHgDED6xqwXJfONCjF5VoE0cXEiurh3XauygxzeDzgtXUqvLkxFzzA==", "dev": true }, @@ -833,7 +1018,7 @@ }, "@types/fs-extra": { "version": "4.0.8", - "resolved": "https://registry.npmjs.org/@types/fs-extra/-/fs-extra-4.0.8.tgz", + "resolved": "http://registry.npmjs.org/@types/fs-extra/-/fs-extra-4.0.8.tgz", "integrity": "sha512-Z5nu9Pbxj9yNeXIK3UwGlRdJth4cZ5sCq05nI7FaI6B0oz28nxkOtp6Lsz0ZnmLHJGvOJfB/VHxSTbVq/i6ujA==", "dev": true, "requires": { @@ -885,7 +1070,7 @@ }, "@types/html-minifier": { "version": "3.5.2", - "resolved": "https://registry.npmjs.org/@types/html-minifier/-/html-minifier-3.5.2.tgz", + "resolved": "http://registry.npmjs.org/@types/html-minifier/-/html-minifier-3.5.2.tgz", "integrity": "sha512-yikK28/KlVyf8g9i/k+TDFlteLuZ6QQTUdVqvKtzEB+8DSLCTjxfh6IK45KnW4rYFI3Y8T4LWpYJMTmfJleWaQ==", "dev": true, "requires": { @@ -896,7 +1081,7 @@ }, "@types/is-windows": { "version": "0.2.0", - "resolved": "https://registry.npmjs.org/@types/is-windows/-/is-windows-0.2.0.tgz", + "resolved": "http://registry.npmjs.org/@types/is-windows/-/is-windows-0.2.0.tgz", "integrity": "sha1-byTuSHMdMRaOpRBhDW3RXl/Jxv8=", "dev": true }, @@ -915,7 +1100,7 @@ }, "@types/marked": { "version": "0.0.28", - "resolved": "https://registry.npmjs.org/@types/marked/-/marked-0.0.28.tgz", + "resolved": "http://registry.npmjs.org/@types/marked/-/marked-0.0.28.tgz", "integrity": "sha1-RLp1Tp+lFDJYPo6zCnxN0km1L6o=", "dev": true }, @@ -927,7 +1112,7 @@ }, "@types/minimatch": { "version": "2.0.29", - "resolved": "https://registry.npmjs.org/@types/minimatch/-/minimatch-2.0.29.tgz", + "resolved": "http://registry.npmjs.org/@types/minimatch/-/minimatch-2.0.29.tgz", "integrity": "sha1-UALhT3Xi1x5WQoHfBDHIwbSio2o=", "dev": true }, @@ -939,7 +1124,7 @@ }, "@types/mz": { "version": "0.0.29", - "resolved": "https://registry.npmjs.org/@types/mz/-/mz-0.0.29.tgz", + "resolved": "http://registry.npmjs.org/@types/mz/-/mz-0.0.29.tgz", "integrity": "sha1-vCRyjGSZc/HHhR6QM/nOUlZowns=", "dev": true, "requires": { @@ -955,7 +1140,7 @@ }, "@types/opn": { "version": "3.0.28", - "resolved": "https://registry.npmjs.org/@types/opn/-/opn-3.0.28.tgz", + "resolved": "http://registry.npmjs.org/@types/opn/-/opn-3.0.28.tgz", "integrity": "sha1-CX0NHJtXSVc6XZbfEyOHu20CEYo=", "dev": true, "requires": { @@ -964,7 +1149,7 @@ }, "@types/parse5": { "version": "2.2.34", - "resolved": "https://registry.npmjs.org/@types/parse5/-/parse5-2.2.34.tgz", + "resolved": "http://registry.npmjs.org/@types/parse5/-/parse5-2.2.34.tgz", "integrity": "sha1-44cKEOgnNacg9i1x3NGDunjvOp0=", "dev": true, "requires": { @@ -973,7 +1158,7 @@ }, "@types/path-is-inside": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/@types/path-is-inside/-/path-is-inside-1.0.0.tgz", + "resolved": "http://registry.npmjs.org/@types/path-is-inside/-/path-is-inside-1.0.0.tgz", "integrity": "sha512-hfnXRGugz+McgX2jxyy5qz9sB21LRzlGn24zlwN2KEgoPtEvjzNRrLtUkOOebPDPZl3Rq7ywKxYvylVcEZDnEw==", "dev": true }, @@ -991,7 +1176,7 @@ }, "@types/relateurl": { "version": "0.2.28", - "resolved": "https://registry.npmjs.org/@types/relateurl/-/relateurl-0.2.28.tgz", + "resolved": "http://registry.npmjs.org/@types/relateurl/-/relateurl-0.2.28.tgz", "integrity": "sha1-a9p9uGU/piZD9e5p6facEaOS46Y=", "dev": true }, @@ -1080,7 +1265,7 @@ }, "@types/whatwg-url": { "version": "6.4.0", - "resolved": "https://registry.npmjs.org/@types/whatwg-url/-/whatwg-url-6.4.0.tgz", + "resolved": "http://registry.npmjs.org/@types/whatwg-url/-/whatwg-url-6.4.0.tgz", "integrity": "sha512-tonhlcbQ2eho09am6RHnHOgvtDfDYINd5rgxD+2YSkKENooVCFsWizJz139MQW/PV8FfClyKrNe9ZbdHrSCxGg==", "dev": true, "requires": { @@ -1139,7 +1324,7 @@ }, "acorn-jsx": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-3.0.1.tgz", + "resolved": "http://registry.npmjs.org/acorn-jsx/-/acorn-jsx-3.0.1.tgz", "integrity": "sha1-r9+UiPsezvyDSPb7IvRk4ypYs2s=", "dev": true, "requires": { @@ -1148,7 +1333,7 @@ "dependencies": { "acorn": { "version": "3.3.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-3.3.0.tgz", + "resolved": "http://registry.npmjs.org/acorn/-/acorn-3.3.0.tgz", "integrity": "sha1-ReN/s56No/JbruP/U2niu18iAXo=", "dev": true } @@ -1232,6 +1417,17 @@ "integrity": "sha1-q8av7tzqUugJzcA3au0845Y10X8=", "dev": true }, + "anymatch": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-2.0.0.tgz", + "integrity": "sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw==", + "dev": true, + "optional": true, + "requires": { + "micromatch": "^3.1.4", + "normalize-path": "^2.1.1" + } + }, "append-field": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/append-field/-/append-field-1.0.0.tgz", @@ -1390,6 +1586,13 @@ "lodash": "^4.17.10" } }, + "async-each": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/async-each/-/async-each-1.0.1.tgz", + "integrity": "sha1-GdOGodntxufByF04iu28xW0zYC0=", + "dev": true, + "optional": true + }, "async-limiter": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.0.tgz", @@ -1445,7 +1648,7 @@ }, "chalk": { "version": "1.1.3", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "resolved": "http://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { @@ -1464,7 +1667,7 @@ }, "strip-ansi": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "resolved": "http://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { @@ -1497,7 +1700,7 @@ "dependencies": { "jsesc": { "version": "1.3.0", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-1.3.0.tgz", + "resolved": "http://registry.npmjs.org/jsesc/-/jsesc-1.3.0.tgz", "integrity": "sha1-RsP+yMGJKxKwgz25vHYiF226s0s=", "dev": true }, @@ -1523,7 +1726,7 @@ }, "babel-helper-is-nodes-equiv": { "version": "0.0.1", - "resolved": "https://registry.npmjs.org/babel-helper-is-nodes-equiv/-/babel-helper-is-nodes-equiv-0.0.1.tgz", + "resolved": "http://registry.npmjs.org/babel-helper-is-nodes-equiv/-/babel-helper-is-nodes-equiv-0.0.1.tgz", "integrity": "sha1-NOmzALFHnd2Y7HfqC76TQt/jloQ=", "dev": true }, @@ -1663,25 +1866,25 @@ }, "babel-plugin-transform-member-expression-literals": { "version": "6.10.0-alpha.f95869d4", - "resolved": "https://registry.npmjs.org/babel-plugin-transform-member-expression-literals/-/babel-plugin-transform-member-expression-literals-6.10.0-alpha.f95869d4.tgz", + "resolved": "http://registry.npmjs.org/babel-plugin-transform-member-expression-literals/-/babel-plugin-transform-member-expression-literals-6.10.0-alpha.f95869d4.tgz", "integrity": "sha1-Jy69Ki1DQbhsJNzYQ3SuWqNwKHQ=", "dev": true }, "babel-plugin-transform-merge-sibling-variables": { "version": "6.10.0-alpha.f95869d4", - "resolved": "https://registry.npmjs.org/babel-plugin-transform-merge-sibling-variables/-/babel-plugin-transform-merge-sibling-variables-6.10.0-alpha.f95869d4.tgz", + "resolved": "http://registry.npmjs.org/babel-plugin-transform-merge-sibling-variables/-/babel-plugin-transform-merge-sibling-variables-6.10.0-alpha.f95869d4.tgz", "integrity": "sha1-SKMw0oKT4xjQcXXCYMdIWec5i0M=", "dev": true }, "babel-plugin-transform-minify-booleans": { "version": "6.10.0-alpha.f95869d4", - "resolved": "https://registry.npmjs.org/babel-plugin-transform-minify-booleans/-/babel-plugin-transform-minify-booleans-6.10.0-alpha.f95869d4.tgz", + "resolved": "http://registry.npmjs.org/babel-plugin-transform-minify-booleans/-/babel-plugin-transform-minify-booleans-6.10.0-alpha.f95869d4.tgz", "integrity": "sha1-He72nCITUDipHeH10T11njRkxDw=", "dev": true }, "babel-plugin-transform-property-literals": { "version": "6.10.0-alpha.f95869d4", - "resolved": "https://registry.npmjs.org/babel-plugin-transform-property-literals/-/babel-plugin-transform-property-literals-6.10.0-alpha.f95869d4.tgz", + "resolved": "http://registry.npmjs.org/babel-plugin-transform-property-literals/-/babel-plugin-transform-property-literals-6.10.0-alpha.f95869d4.tgz", "integrity": "sha1-NxJ6qgQSXD0Iv5XNtajx0uRMpFM=", "dev": true, "requires": { @@ -1696,13 +1899,13 @@ }, "babel-plugin-transform-remove-console": { "version": "6.10.0-alpha.f95869d4", - "resolved": "https://registry.npmjs.org/babel-plugin-transform-remove-console/-/babel-plugin-transform-remove-console-6.10.0-alpha.f95869d4.tgz", + "resolved": "http://registry.npmjs.org/babel-plugin-transform-remove-console/-/babel-plugin-transform-remove-console-6.10.0-alpha.f95869d4.tgz", "integrity": "sha1-xXF6+fdpGLKCHPrvRNgkXU6pQiw=", "dev": true }, "babel-plugin-transform-remove-debugger": { "version": "6.10.0-alpha.f95869d4", - "resolved": "https://registry.npmjs.org/babel-plugin-transform-remove-debugger/-/babel-plugin-transform-remove-debugger-6.10.0-alpha.f95869d4.tgz", + "resolved": "http://registry.npmjs.org/babel-plugin-transform-remove-debugger/-/babel-plugin-transform-remove-debugger-6.10.0-alpha.f95869d4.tgz", "integrity": "sha1-H8NcKcfAh4zzDlWKczZRkG6IjkQ=", "dev": true }, @@ -1717,19 +1920,19 @@ }, "babel-plugin-transform-simplify-comparison-operators": { "version": "6.10.0-alpha.f95869d4", - "resolved": "https://registry.npmjs.org/babel-plugin-transform-simplify-comparison-operators/-/babel-plugin-transform-simplify-comparison-operators-6.10.0-alpha.f95869d4.tgz", + "resolved": "http://registry.npmjs.org/babel-plugin-transform-simplify-comparison-operators/-/babel-plugin-transform-simplify-comparison-operators-6.10.0-alpha.f95869d4.tgz", "integrity": "sha1-9UmabcPtaGvaUzY4ZrZ92ndMW+0=", "dev": true }, "babel-plugin-transform-undefined-to-void": { "version": "6.10.0-alpha.f95869d4", - "resolved": "https://registry.npmjs.org/babel-plugin-transform-undefined-to-void/-/babel-plugin-transform-undefined-to-void-6.10.0-alpha.f95869d4.tgz", + "resolved": "http://registry.npmjs.org/babel-plugin-transform-undefined-to-void/-/babel-plugin-transform-undefined-to-void-6.10.0-alpha.f95869d4.tgz", "integrity": "sha1-F1oaMJDmFkA/jIGc3Ooa7LZlI7I=", "dev": true }, "babel-preset-minify": { "version": "0.4.0-alpha.caaefb4c", - "resolved": "https://registry.npmjs.org/babel-preset-minify/-/babel-preset-minify-0.4.0-alpha.caaefb4c.tgz", + "resolved": "http://registry.npmjs.org/babel-preset-minify/-/babel-preset-minify-0.4.0-alpha.caaefb4c.tgz", "integrity": "sha1-pQUsWVXdl9JGmbKB/amjAuqMGHE=", "dev": true, "requires": { @@ -1937,9 +2140,16 @@ "callsite": "1.0.0" } }, + "binary-extensions": { + "version": "1.12.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.12.0.tgz", + "integrity": "sha512-DYWGk01lDcxeS/K9IHPGWfT8PsJmbXRtRd2Sx72Tnb8pcYZQFF1oSDb8hJtS1vhp212q1Rzi5dUf9+nq0o9UIg==", + "dev": true, + "optional": true + }, "bl": { "version": "1.2.2", - "resolved": "https://registry.npmjs.org/bl/-/bl-1.2.2.tgz", + "resolved": "http://registry.npmjs.org/bl/-/bl-1.2.2.tgz", "integrity": "sha512-e8tQYnZodmebYDWGH7KMRvtzKXaJHx3BbilrgZCfvyLUYdKpK1t5PSPmpkny/SgiTSCnjfLW7v5rlONXVFkQEA==", "dev": true, "requires": { @@ -2162,7 +2372,7 @@ }, "readable-stream": { "version": "1.1.14", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.1.14.tgz", + "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-1.1.14.tgz", "integrity": "sha1-fPTFTvZI44EwhMY23SB54WbAgdk=", "dev": true, "requires": { @@ -2174,7 +2384,7 @@ }, "string_decoder": { "version": "0.10.31", - "resolved": "http://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=", "dev": true } @@ -2227,7 +2437,7 @@ }, "camelcase-keys": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/camelcase-keys/-/camelcase-keys-2.1.0.tgz", + "resolved": "http://registry.npmjs.org/camelcase-keys/-/camelcase-keys-2.1.0.tgz", "integrity": "sha1-MIvur/3ygRkFHvodkyITyRuPkuc=", "dev": true, "requires": { @@ -2245,7 +2455,7 @@ }, "cancel-token": { "version": "0.1.1", - "resolved": "https://registry.npmjs.org/cancel-token/-/cancel-token-0.1.1.tgz", + "resolved": "http://registry.npmjs.org/cancel-token/-/cancel-token-0.1.1.tgz", "integrity": "sha1-wYGXZ0uxyEwdaTPr8V2NWlznm08=", "dev": true, "requires": { @@ -2309,6 +2519,63 @@ "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=", "dev": true }, + "chokidar": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-2.0.4.tgz", + "integrity": "sha512-z9n7yt9rOvIJrMhvDtDictKrkFHeihkNl6uWMmZlmL6tJtX9Cs+87oK+teBx+JIgzvbX3yZHT3eF8vpbDxHJXQ==", + "dev": true, + "optional": true, + "requires": { + "anymatch": "^2.0.0", + "async-each": "^1.0.0", + "braces": "^2.3.0", + "fsevents": "^1.2.2", + "glob-parent": "^3.1.0", + "inherits": "^2.0.1", + "is-binary-path": "^1.0.0", + "is-glob": "^4.0.0", + "lodash.debounce": "^4.0.8", + "normalize-path": "^2.1.1", + "path-is-absolute": "^1.0.0", + "readdirp": "^2.0.0", + "upath": "^1.0.5" + }, + "dependencies": { + "glob-parent": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-3.1.0.tgz", + "integrity": "sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4=", + "dev": true, + "optional": true, + "requires": { + "is-glob": "^3.1.0", + "path-dirname": "^1.0.0" + }, + "dependencies": { + "is-glob": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-3.1.0.tgz", + "integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=", + "dev": true, + "optional": true, + "requires": { + "is-extglob": "^2.1.0" + } + } + } + }, + "is-glob": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.0.tgz", + "integrity": "sha1-lSHHaEXMJhCoUgPd8ICpWML/q8A=", + "dev": true, + "optional": true, + "requires": { + "is-extglob": "^2.1.1" + } + } + } + }, "chownr": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.1.tgz", @@ -2355,7 +2622,7 @@ }, "cleankill": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/cleankill/-/cleankill-2.0.0.tgz", + "resolved": "http://registry.npmjs.org/cleankill/-/cleankill-2.0.0.tgz", "integrity": "sha1-WYMN/ItBHVPccq0J1Fp46jMWGpE=", "dev": true }, @@ -2492,7 +2759,7 @@ }, "commander": { "version": "2.15.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.15.1.tgz", + "resolved": "http://registry.npmjs.org/commander/-/commander-2.15.1.tgz", "integrity": "sha512-VlfT9F3V0v+jr4yxPc5gg9s62/fIVWsd2Bk2iD435um1NlGMYdVCq+MjcXnhYq2icNOizHr1kK+5TI6H0Hy0ag==", "dev": true }, @@ -2804,7 +3071,7 @@ }, "deep-assign": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/deep-assign/-/deep-assign-2.0.0.tgz", + "resolved": "http://registry.npmjs.org/deep-assign/-/deep-assign-2.0.0.tgz", "integrity": "sha1-6+BrHwfwja5ZdiDj3RYi83GhxXI=", "dev": true, "requires": { @@ -2947,7 +3214,7 @@ }, "readable-stream": { "version": "1.1.14", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.1.14.tgz", + "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-1.1.14.tgz", "integrity": "sha1-fPTFTvZI44EwhMY23SB54WbAgdk=", "dev": true, "requires": { @@ -2959,7 +3226,7 @@ }, "string_decoder": { "version": "0.10.31", - "resolved": "http://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=", "dev": true } @@ -3011,7 +3278,7 @@ }, "duplexer": { "version": "0.1.1", - "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.1.tgz", + "resolved": "http://registry.npmjs.org/duplexer/-/duplexer-0.1.1.tgz", "integrity": "sha1-rOb/gIwc5mtX0ev5eXessCM0z8E=", "dev": true }, @@ -3104,7 +3371,7 @@ }, "engine.io-client": { "version": "3.2.1", - "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-3.2.1.tgz", + "resolved": "http://registry.npmjs.org/engine.io-client/-/engine.io-client-3.2.1.tgz", "integrity": "sha512-y5AbkytWeM4jQr7m/koQLc5AxpRKC1hEVUb/s1FUAWEJq5AzJJ4NLvzuKPuxtDi5Mq755WuDvZ6Iv2rXj4PTzw==", "dev": true, "requires": { @@ -3183,7 +3450,7 @@ }, "espree": { "version": "3.5.4", - "resolved": "https://registry.npmjs.org/espree/-/espree-3.5.4.tgz", + "resolved": "http://registry.npmjs.org/espree/-/espree-3.5.4.tgz", "integrity": "sha512-yAcIQxtmMiB/jL32dzEp2enBeidsB7xWPLNiw3IIkpVds1P+h7qF9YwJq1yUNzp2OKXgAprs4F61ih66UsoD1A==", "dev": true, "requires": { @@ -3276,7 +3543,7 @@ }, "expand-range": { "version": "1.8.2", - "resolved": "http://registry.npmjs.org/expand-range/-/expand-range-1.8.2.tgz", + "resolved": "https://registry.npmjs.org/expand-range/-/expand-range-1.8.2.tgz", "integrity": "sha1-opnv/TNf4nIeuujiV+x5ZE/IUzc=", "dev": true, "requires": { @@ -3592,7 +3859,7 @@ }, "finalhandler": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.1.tgz", + "resolved": "http://registry.npmjs.org/finalhandler/-/finalhandler-1.1.1.tgz", "integrity": "sha512-Y1GUDo39ez4aHAw7MysnUD5JzYX+WaIj8I57kO3aEPT1fFRL4sr7mjei97FgnwhAyyzRYmQZaTHb2+9uZ1dPtg==", "dev": true, "requires": { @@ -3633,7 +3900,7 @@ "dependencies": { "async": { "version": "0.2.10", - "resolved": "https://registry.npmjs.org/async/-/async-0.2.10.tgz", + "resolved": "http://registry.npmjs.org/async/-/async-0.2.10.tgz", "integrity": "sha1-trvgsGdLnXGXCMo43owjfLUmw9E=", "dev": true } @@ -3778,12 +4045,547 @@ "universalify": "^0.1.0" } }, + "fs-readdir-recursive": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/fs-readdir-recursive/-/fs-readdir-recursive-1.1.0.tgz", + "integrity": "sha512-GNanXlVr2pf02+sPN40XN8HG+ePaNcvM0q5mZBd668Obwb0yD5GiUbZOFgwn8kGMY6I3mdyDJzieUy3PTYyTRA==", + "dev": true + }, "fs.realpath": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", "dev": true }, + "fsevents": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-1.2.4.tgz", + "integrity": "sha512-z8H8/diyk76B7q5wg+Ud0+CqzcAF3mBBI/bA5ne5zrRUUIvNkJY//D3BqyH571KuAC4Nr7Rw7CjWX4r0y9DvNg==", + "dev": true, + "optional": true, + "requires": { + "nan": "^2.9.2", + "node-pre-gyp": "^0.10.0" + }, + "dependencies": { + "abbrev": { + "version": "1.1.1", + "bundled": true, + "dev": true, + "optional": true + }, + "ansi-regex": { + "version": "2.1.1", + "bundled": true, + "dev": true + }, + "aproba": { + "version": "1.2.0", + "bundled": true, + "dev": true, + "optional": true + }, + "are-we-there-yet": { + "version": "1.1.4", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "delegates": "^1.0.0", + "readable-stream": "^2.0.6" + } + }, + "balanced-match": { + "version": "1.0.0", + "bundled": true, + "dev": true + }, + "brace-expansion": { + "version": "1.1.11", + "bundled": true, + "dev": true, + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "chownr": { + "version": "1.0.1", + "bundled": true, + "dev": true, + "optional": true + }, + "code-point-at": { + "version": "1.1.0", + "bundled": true, + "dev": true + }, + "concat-map": { + "version": "0.0.1", + "bundled": true, + "dev": true + }, + "console-control-strings": { + "version": "1.1.0", + "bundled": true, + "dev": true + }, + "core-util-is": { + "version": "1.0.2", + "bundled": true, + "dev": true, + "optional": true + }, + "debug": { + "version": "2.6.9", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "ms": "2.0.0" + } + }, + "deep-extend": { + "version": "0.5.1", + "bundled": true, + "dev": true, + "optional": true + }, + "delegates": { + "version": "1.0.0", + "bundled": true, + "dev": true, + "optional": true + }, + "detect-libc": { + "version": "1.0.3", + "bundled": true, + "dev": true, + "optional": true + }, + "fs-minipass": { + "version": "1.2.5", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "minipass": "^2.2.1" + } + }, + "fs.realpath": { + "version": "1.0.0", + "bundled": true, + "dev": true, + "optional": true + }, + "gauge": { + "version": "2.7.4", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "aproba": "^1.0.3", + "console-control-strings": "^1.0.0", + "has-unicode": "^2.0.0", + "object-assign": "^4.1.0", + "signal-exit": "^3.0.0", + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wide-align": "^1.1.0" + } + }, + "glob": { + "version": "7.1.2", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "has-unicode": { + "version": "2.0.1", + "bundled": true, + "dev": true, + "optional": true + }, + "iconv-lite": { + "version": "0.4.21", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "safer-buffer": "^2.1.0" + } + }, + "ignore-walk": { + "version": "3.0.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "minimatch": "^3.0.4" + } + }, + "inflight": { + "version": "1.0.6", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.3", + "bundled": true, + "dev": true + }, + "ini": { + "version": "1.3.5", + "bundled": true, + "dev": true, + "optional": true + }, + "is-fullwidth-code-point": { + "version": "1.0.0", + "bundled": true, + "dev": true, + "requires": { + "number-is-nan": "^1.0.0" + } + }, + "isarray": { + "version": "1.0.0", + "bundled": true, + "dev": true, + "optional": true + }, + "minimatch": { + "version": "3.0.4", + "bundled": true, + "dev": true, + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minimist": { + "version": "0.0.8", + "bundled": true, + "dev": true + }, + "minipass": { + "version": "2.2.4", + "bundled": true, + "dev": true, + "requires": { + "safe-buffer": "^5.1.1", + "yallist": "^3.0.0" + } + }, + "minizlib": { + "version": "1.1.0", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "minipass": "^2.2.1" + } + }, + "mkdirp": { + "version": "0.5.1", + "bundled": true, + "dev": true, + "requires": { + "minimist": "0.0.8" + } + }, + "ms": { + "version": "2.0.0", + "bundled": true, + "dev": true, + "optional": true + }, + "needle": { + "version": "2.2.0", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "debug": "^2.1.2", + "iconv-lite": "^0.4.4", + "sax": "^1.2.4" + } + }, + "node-pre-gyp": { + "version": "0.10.0", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "detect-libc": "^1.0.2", + "mkdirp": "^0.5.1", + "needle": "^2.2.0", + "nopt": "^4.0.1", + "npm-packlist": "^1.1.6", + "npmlog": "^4.0.2", + "rc": "^1.1.7", + "rimraf": "^2.6.1", + "semver": "^5.3.0", + "tar": "^4" + } + }, + "nopt": { + "version": "4.0.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "abbrev": "1", + "osenv": "^0.1.4" + } + }, + "npm-bundled": { + "version": "1.0.3", + "bundled": true, + "dev": true, + "optional": true + }, + "npm-packlist": { + "version": "1.1.10", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "ignore-walk": "^3.0.1", + "npm-bundled": "^1.0.1" + } + }, + "npmlog": { + "version": "4.1.2", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "are-we-there-yet": "~1.1.2", + "console-control-strings": "~1.1.0", + "gauge": "~2.7.3", + "set-blocking": "~2.0.0" + } + }, + "number-is-nan": { + "version": "1.0.1", + "bundled": true, + "dev": true + }, + "object-assign": { + "version": "4.1.1", + "bundled": true, + "dev": true, + "optional": true + }, + "once": { + "version": "1.4.0", + "bundled": true, + "dev": true, + "requires": { + "wrappy": "1" + } + }, + "os-homedir": { + "version": "1.0.2", + "bundled": true, + "dev": true, + "optional": true + }, + "os-tmpdir": { + "version": "1.0.2", + "bundled": true, + "dev": true, + "optional": true + }, + "osenv": { + "version": "0.1.5", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "os-homedir": "^1.0.0", + "os-tmpdir": "^1.0.0" + } + }, + "path-is-absolute": { + "version": "1.0.1", + "bundled": true, + "dev": true, + "optional": true + }, + "process-nextick-args": { + "version": "2.0.0", + "bundled": true, + "dev": true, + "optional": true + }, + "rc": { + "version": "1.2.7", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "deep-extend": "^0.5.1", + "ini": "~1.3.0", + "minimist": "^1.2.0", + "strip-json-comments": "~2.0.1" + }, + "dependencies": { + "minimist": { + "version": "1.2.0", + "bundled": true, + "dev": true, + "optional": true + } + } + }, + "readable-stream": { + "version": "2.3.6", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "rimraf": { + "version": "2.6.2", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "glob": "^7.0.5" + } + }, + "safe-buffer": { + "version": "5.1.1", + "bundled": true, + "dev": true + }, + "safer-buffer": { + "version": "2.1.2", + "bundled": true, + "dev": true, + "optional": true + }, + "sax": { + "version": "1.2.4", + "bundled": true, + "dev": true, + "optional": true + }, + "semver": { + "version": "5.5.0", + "bundled": true, + "dev": true, + "optional": true + }, + "set-blocking": { + "version": "2.0.0", + "bundled": true, + "dev": true, + "optional": true + }, + "signal-exit": { + "version": "3.0.2", + "bundled": true, + "dev": true, + "optional": true + }, + "string-width": { + "version": "1.0.2", + "bundled": true, + "dev": true, + "requires": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" + } + }, + "string_decoder": { + "version": "1.1.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "safe-buffer": "~5.1.0" + } + }, + "strip-ansi": { + "version": "3.0.1", + "bundled": true, + "dev": true, + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "strip-json-comments": { + "version": "2.0.1", + "bundled": true, + "dev": true, + "optional": true + }, + "tar": { + "version": "4.4.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "chownr": "^1.0.1", + "fs-minipass": "^1.2.5", + "minipass": "^2.2.4", + "minizlib": "^1.1.0", + "mkdirp": "^0.5.0", + "safe-buffer": "^5.1.1", + "yallist": "^3.0.2" + } + }, + "util-deprecate": { + "version": "1.0.2", + "bundled": true, + "dev": true, + "optional": true + }, + "wide-align": { + "version": "1.1.2", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "string-width": "^1.0.2" + } + }, + "wrappy": { + "version": "1.0.2", + "bundled": true, + "dev": true + }, + "yallist": { + "version": "3.0.2", + "bundled": true, + "dev": true + } + } + }, "gauge": { "version": "2.7.4", "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", @@ -3828,7 +4630,7 @@ }, "strip-ansi": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "resolved": "http://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { @@ -3851,7 +4653,7 @@ }, "get-stream": { "version": "3.0.0", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz", + "resolved": "http://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz", "integrity": "sha1-jpQ9E1jcN1VQVOy+LtsFqhdO3hQ=", "dev": true }, @@ -4081,7 +4883,7 @@ }, "readable-stream": { "version": "1.0.34", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.34.tgz", + "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-1.0.34.tgz", "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", "dev": true, "requires": { @@ -4093,13 +4895,13 @@ }, "string_decoder": { "version": "0.10.31", - "resolved": "http://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=", "dev": true }, "through2": { "version": "0.6.5", - "resolved": "https://registry.npmjs.org/through2/-/through2-0.6.5.tgz", + "resolved": "http://registry.npmjs.org/through2/-/through2-0.6.5.tgz", "integrity": "sha1-QaucZ7KdVyCQcUEOHXp6lozTrUg=", "dev": true, "requires": { @@ -4150,7 +4952,7 @@ }, "got": { "version": "6.7.1", - "resolved": "https://registry.npmjs.org/got/-/got-6.7.1.tgz", + "resolved": "http://registry.npmjs.org/got/-/got-6.7.1.tgz", "integrity": "sha1-JAzQV4WpoY5WHcG0S0HHY+8ejbA=", "dev": true, "requires": { @@ -4223,7 +5025,7 @@ }, "handle-thing": { "version": "1.2.5", - "resolved": "https://registry.npmjs.org/handle-thing/-/handle-thing-1.2.5.tgz", + "resolved": "http://registry.npmjs.org/handle-thing/-/handle-thing-1.2.5.tgz", "integrity": "sha1-/Xqtcmvxpf0W38KbL3pmAdJxOcQ=", "dev": true }, @@ -4392,7 +5194,7 @@ }, "hoek": { "version": "4.2.1", - "resolved": "https://registry.npmjs.org/hoek/-/hoek-4.2.1.tgz", + "resolved": "http://registry.npmjs.org/hoek/-/hoek-4.2.1.tgz", "integrity": "sha512-QLg82fGkfnJ/4iy1xZ81/9SIJiq1NGFUMGs6ParyjBZr6jW2Ufj/snDqTHixNlHdPNwN2RLVD0Pi3igeK9+JfA==", "dev": true }, @@ -4470,7 +5272,7 @@ }, "http-errors": { "version": "1.6.3", - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.6.3.tgz", + "resolved": "http://registry.npmjs.org/http-errors/-/http-errors-1.6.3.tgz", "integrity": "sha1-i1VoC7S+KDoLW/TqLjhYC+HZMg0=", "dev": true, "requires": { @@ -4747,6 +5549,16 @@ "integrity": "sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==", "dev": true }, + "is-binary-path": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-1.0.1.tgz", + "integrity": "sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg=", + "dev": true, + "optional": true, + "requires": { + "binary-extensions": "^1.0.0" + } + }, "is-buffer": { "version": "1.1.6", "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", @@ -4755,7 +5567,7 @@ }, "is-builtin-module": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-builtin-module/-/is-builtin-module-1.0.0.tgz", + "resolved": "http://registry.npmjs.org/is-builtin-module/-/is-builtin-module-1.0.0.tgz", "integrity": "sha1-VAVy0096wxGfj3bDDLwbHgN6/74=", "dev": true, "requires": { @@ -4913,7 +5725,7 @@ }, "is-obj": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-obj/-/is-obj-1.0.1.tgz", + "resolved": "http://registry.npmjs.org/is-obj/-/is-obj-1.0.1.tgz", "integrity": "sha1-PkcprB9f3gJc19g6iW2rn09n2w8=", "dev": true }, @@ -4926,6 +5738,12 @@ "path-is-inside": "^1.0.1" } }, + "is-plain-obj": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", + "integrity": "sha1-caUMhCnfync8kqOQpKA7OfzVHT4=", + "dev": true + }, "is-plain-object": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", @@ -5193,7 +6011,7 @@ }, "load-json-file": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz", + "resolved": "http://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz", "integrity": "sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA=", "dev": true, "requires": { @@ -5222,6 +6040,13 @@ "integrity": "sha1-soqmKIorn8ZRA1x3EfZathkDMaY=", "dev": true }, + "lodash.debounce": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz", + "integrity": "sha1-gteb/zCmfEAF/9XiUVMArZyk168=", + "dev": true, + "optional": true + }, "lodash.defaults": { "version": "4.2.0", "resolved": "https://registry.npmjs.org/lodash.defaults/-/lodash.defaults-4.2.0.tgz", @@ -5347,7 +6172,7 @@ }, "magic-string": { "version": "0.22.5", - "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.22.5.tgz", + "resolved": "http://registry.npmjs.org/magic-string/-/magic-string-0.22.5.tgz", "integrity": "sha512-oreip9rJZkzvA8Qzk9HFs8fZGF/u7H/gtrE8EN6RjKJ9kh2HlC+yQ2QezifqTZfGyiuAV0dRv5a+y/8gBb1m9w==", "dev": true, "requires": { @@ -5394,7 +6219,7 @@ }, "marked": { "version": "0.3.19", - "resolved": "https://registry.npmjs.org/marked/-/marked-0.3.19.tgz", + "resolved": "http://registry.npmjs.org/marked/-/marked-0.3.19.tgz", "integrity": "sha512-ea2eGWOqNxPcXv8dyERdSr/6FmzvWwzjMxpfGB/sbMccXoct+xY+YukPD+QTUZwyvK7BZwcr4m21WBOW41pAkg==", "dev": true }, @@ -5426,13 +6251,13 @@ }, "media-typer": { "version": "0.3.0", - "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", + "resolved": "http://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", "integrity": "sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g=", "dev": true }, "meow": { "version": "3.7.0", - "resolved": "https://registry.npmjs.org/meow/-/meow-3.7.0.tgz", + "resolved": "http://registry.npmjs.org/meow/-/meow-3.7.0.tgz", "integrity": "sha1-cstmi0JSKCkKu/qFaJJYcwioAfs=", "dev": true, "requires": { @@ -5450,7 +6275,7 @@ "dependencies": { "minimist": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "resolved": "http://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true } @@ -5551,7 +6376,7 @@ }, "minimist": { "version": "0.0.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", + "resolved": "http://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", "dev": true }, @@ -5578,7 +6403,7 @@ }, "mkdirp": { "version": "0.5.1", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", + "resolved": "http://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", "dev": true, "requires": { @@ -5653,6 +6478,13 @@ "thenify-all": "^1.0.0" } }, + "nan": { + "version": "2.12.1", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.12.1.tgz", + "integrity": "sha512-JY7V6lRkStKcKTvHO5NVSQRv+RV+FIL5pvDoLiAtSL9pKlC5x9PKQcZDsq7m4FO4d57mkhC6Z+QhAh3Jdk5JFw==", + "dev": true, + "optional": true + }, "nanomatch": { "version": "1.2.13", "resolved": "https://registry.npmjs.org/nanomatch/-/nanomatch-1.2.13.tgz", @@ -5733,7 +6565,7 @@ }, "chalk": { "version": "0.4.0", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-0.4.0.tgz", + "resolved": "http://registry.npmjs.org/chalk/-/chalk-0.4.0.tgz", "integrity": "sha1-UZmj3c0MHv4jvAjBsCewYXbgxk8=", "dev": true, "requires": { @@ -5744,7 +6576,7 @@ }, "strip-ansi": { "version": "0.1.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-0.1.1.tgz", + "resolved": "http://registry.npmjs.org/strip-ansi/-/strip-ansi-0.1.1.tgz", "integrity": "sha1-OeipjQRNFQZgq+SmgIrPcLt7yZE=", "dev": true } @@ -5920,7 +6752,7 @@ }, "opn": { "version": "3.0.3", - "resolved": "https://registry.npmjs.org/opn/-/opn-3.0.3.tgz", + "resolved": "http://registry.npmjs.org/opn/-/opn-3.0.3.tgz", "integrity": "sha1-ttmec5n3jWXDuq/+8fsojpuFJDo=", "dev": true, "requires": { @@ -5949,13 +6781,13 @@ }, "os-homedir": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", + "resolved": "http://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", "dev": true }, "os-tmpdir": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "resolved": "http://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", "dev": true }, @@ -5969,6 +6801,17 @@ "os-tmpdir": "^1.0.0" } }, + "output-file-sync": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/output-file-sync/-/output-file-sync-2.0.1.tgz", + "integrity": "sha512-mDho4qm7WgIXIGf4eYU1RHN2UU5tPfVYVSRwDJw0uTmj35DQUt/eNp19N7v6T3SrR0ESTEf2up2CGO73qI35zQ==", + "dev": true, + "requires": { + "graceful-fs": "^4.1.11", + "is-plain-obj": "^1.1.0", + "mkdirp": "^0.5.1" + } + }, "p-finally": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", @@ -6093,7 +6936,7 @@ }, "path-is-absolute": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "resolved": "http://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", "dev": true }, @@ -6165,7 +7008,7 @@ }, "pify": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz", + "resolved": "http://registry.npmjs.org/pify/-/pify-2.3.0.tgz", "integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw=", "dev": true }, @@ -6272,7 +7115,7 @@ }, "chalk": { "version": "1.1.3", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "resolved": "http://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { @@ -6285,7 +7128,7 @@ }, "strip-ansi": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "resolved": "http://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { @@ -6384,7 +7227,7 @@ }, "@types/resolve": { "version": "0.0.7", - "resolved": "https://registry.npmjs.org/@types/resolve/-/resolve-0.0.7.tgz", + "resolved": "http://registry.npmjs.org/@types/resolve/-/resolve-0.0.7.tgz", "integrity": "sha512-GPewdjkb0Q76o459qgp6pBLzJj/bD3oveS2kfLhIkZ9U3t3AFKtl5DlFB6lGTw0iZmcmxoGC8lpLW3NNJKrN9A==", "dev": true, "requires": { @@ -6611,7 +7454,7 @@ "dependencies": { "minimist": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "resolved": "http://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true } @@ -6631,7 +7474,7 @@ }, "pretty-bytes": { "version": "4.0.2", - "resolved": "http://registry.npmjs.org/pretty-bytes/-/pretty-bytes-4.0.2.tgz", + "resolved": "https://registry.npmjs.org/pretty-bytes/-/pretty-bytes-4.0.2.tgz", "integrity": "sha1-sr+C5zUNZcbDOqlaqlpPYyf2HNk=", "dev": true }, @@ -6756,7 +7599,7 @@ "dependencies": { "minimist": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "resolved": "http://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true } @@ -6785,7 +7628,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "requires": { @@ -6798,6 +7641,18 @@ "util-deprecate": "~1.0.1" } }, + "readdirp": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-2.2.1.tgz", + "integrity": "sha512-1JU/8q+VgFZyxwrJ+SVIOsh+KywWGpds3NTqikiKpDMZWScmAYyKIgqkO+ARvNWJfXeXR1zxz7aHF4u4CyH6vQ==", + "dev": true, + "optional": true, + "requires": { + "graceful-fs": "^4.1.11", + "micromatch": "^3.1.10", + "readable-stream": "^2.0.2" + } + }, "rechoir": { "version": "0.6.2", "resolved": "https://registry.npmjs.org/rechoir/-/rechoir-0.6.2.tgz", @@ -6933,7 +7788,7 @@ "dependencies": { "jsesc": { "version": "0.5.0", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-0.5.0.tgz", + "resolved": "http://registry.npmjs.org/jsesc/-/jsesc-0.5.0.tgz", "integrity": "sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0=", "dev": true } @@ -7114,7 +7969,7 @@ }, "safe-regex": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/safe-regex/-/safe-regex-1.1.0.tgz", + "resolved": "http://registry.npmjs.org/safe-regex/-/safe-regex-1.1.0.tgz", "integrity": "sha1-QKNmnzsHfR6UPURinhV91IAjvy4=", "dev": true, "requires": { @@ -7201,7 +8056,7 @@ }, "minimist": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "resolved": "http://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true, "optional": true @@ -7250,7 +8105,7 @@ "dependencies": { "debug": { "version": "2.1.3", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.1.3.tgz", + "resolved": "http://registry.npmjs.org/debug/-/debug-2.1.3.tgz", "integrity": "sha1-zoqxte6PvuK/o7Yzyrk9NmtjQY4=", "dev": true, "requires": { @@ -7259,7 +8114,7 @@ }, "depd": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/depd/-/depd-1.0.1.tgz", + "resolved": "http://registry.npmjs.org/depd/-/depd-1.0.1.tgz", "integrity": "sha1-gK7GTJ1tl+ZcwqnKqTwKpqv3Oqo=", "dev": true }, @@ -7298,13 +8153,13 @@ }, "mime": { "version": "1.2.11", - "resolved": "http://registry.npmjs.org/mime/-/mime-1.2.11.tgz", + "resolved": "https://registry.npmjs.org/mime/-/mime-1.2.11.tgz", "integrity": "sha1-WCA+7Ybjpe8XrtK32evUfwpg3RA=", "dev": true }, "ms": { "version": "0.7.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-0.7.0.tgz", + "resolved": "http://registry.npmjs.org/ms/-/ms-0.7.0.tgz", "integrity": "sha1-hlvpTC5zl62KV9pqYzpuLzB5i4M=", "dev": true }, @@ -7525,6 +8380,12 @@ "integrity": "sha512-9stIF1utB0ywNHNT7RgiXbdmen8QDCRsrTjw+G9TgKt1Yexjiv8TOWZ6WHsTPz57Yky3DIswZvEqX8fpuHNDtQ==", "dev": true }, + "slash": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-2.0.0.tgz", + "integrity": "sha512-ZYKh3Wh2z1PpEXWr0MpSBZ0V6mZHAQfYevttO11c51CaWjGTaadiKZ+wVt1PbMlDV5qhMFslpZCemhwOK7C89A==", + "dev": true + }, "snapdragon": { "version": "0.8.2", "resolved": "https://registry.npmjs.org/snapdragon/-/snapdragon-0.8.2.tgz", @@ -7700,7 +8561,7 @@ }, "socket.io-parser": { "version": "3.2.0", - "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-3.2.0.tgz", + "resolved": "http://registry.npmjs.org/socket.io-parser/-/socket.io-parser-3.2.0.tgz", "integrity": "sha512-FYiBx7rc/KORMJlgsXysflWx/RIvtqZbyGLlHZvjfmPTPeuD/I8MaW7cfFrj5tRltICJdgwflhfZ3NVVbVLFQA==", "dev": true, "requires": { @@ -7881,7 +8742,7 @@ }, "stacky": { "version": "1.3.1", - "resolved": "https://registry.npmjs.org/stacky/-/stacky-1.3.1.tgz", + "resolved": "http://registry.npmjs.org/stacky/-/stacky-1.3.1.tgz", "integrity": "sha1-PxF+UYe5pz0j+HbWnwXIWxGAShI=", "dev": true, "requires": { @@ -7903,7 +8764,7 @@ }, "chalk": { "version": "1.1.3", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "resolved": "http://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { @@ -7916,13 +8777,13 @@ }, "lodash": { "version": "3.10.1", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-3.10.1.tgz", + "resolved": "http://registry.npmjs.org/lodash/-/lodash-3.10.1.tgz", "integrity": "sha1-W/Rejkm6QYnhfUgnid/RW9FAt7Y=", "dev": true }, "strip-ansi": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "resolved": "http://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { @@ -7997,7 +8858,7 @@ }, "string_decoder": { "version": "1.1.1", - "resolved": "http://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", "dev": true, "requires": { @@ -8040,7 +8901,7 @@ }, "strip-eof": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", + "resolved": "http://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", "integrity": "sha1-u0P/VZim6wXYm1n80SnJgzE2Br8=", "dev": true }, @@ -8175,7 +9036,7 @@ "dependencies": { "rimraf": { "version": "2.2.8", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.2.8.tgz", + "resolved": "http://registry.npmjs.org/rimraf/-/rimraf-2.2.8.tgz", "integrity": "sha1-5Dm+Kq7jJzIZUnMPmaiSnk/FBYI=", "dev": true, "optional": true @@ -8234,7 +9095,7 @@ }, "text-encoding": { "version": "0.6.4", - "resolved": "https://registry.npmjs.org/text-encoding/-/text-encoding-0.6.4.tgz", + "resolved": "http://registry.npmjs.org/text-encoding/-/text-encoding-0.6.4.tgz", "integrity": "sha1-45mpgiV6J22uQou5KEXLcb3CbRk=", "dev": true }, @@ -8731,6 +9592,13 @@ "integrity": "sha1-0vD3N9FrBhXnKmk17QQhRXLVb5c=", "dev": true }, + "upath": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/upath/-/upath-1.1.0.tgz", + "integrity": "sha512-bzpH/oBhoS/QI/YtbkqCg6VEiPYjSZtrHQM6/QnJS6OL9pKUFLqb3aFh4Scvwm45+7iAgiMkLhSbaZxUqmrprw==", + "dev": true, + "optional": true + }, "update-notifier": { "version": "2.5.0", "resolved": "https://registry.npmjs.org/update-notifier/-/update-notifier-2.5.0.tgz", @@ -8984,7 +9852,7 @@ }, "async": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/async/-/async-2.0.1.tgz", + "resolved": "http://registry.npmjs.org/async/-/async-2.0.1.tgz", "integrity": "sha1-twnMAoCpw28J9FNr6CPIOKkEniU=", "dev": true, "requires": { @@ -9039,7 +9907,7 @@ }, "request": { "version": "2.85.0", - "resolved": "https://registry.npmjs.org/request/-/request-2.85.0.tgz", + "resolved": "http://registry.npmjs.org/request/-/request-2.85.0.tgz", "integrity": "sha512-8H7Ehijd4js+s6wuVPLjwORxD4zeuyjYugprdOXlPSqaApmL/QOy+EB/beICHVCHkGMKNh5rvihb5ov+IDw4mg==", "dev": true, "requires": { @@ -9134,7 +10002,7 @@ }, "chalk": { "version": "1.1.3", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "resolved": "http://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { @@ -9147,13 +10015,13 @@ }, "lodash": { "version": "3.10.1", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-3.10.1.tgz", + "resolved": "http://registry.npmjs.org/lodash/-/lodash-3.10.1.tgz", "integrity": "sha1-W/Rejkm6QYnhfUgnid/RW9FAt7Y=", "dev": true }, "strip-ansi": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "resolved": "http://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { @@ -9297,7 +10165,7 @@ }, "xmlbuilder": { "version": "8.2.2", - "resolved": "https://registry.npmjs.org/xmlbuilder/-/xmlbuilder-8.2.2.tgz", + "resolved": "http://registry.npmjs.org/xmlbuilder/-/xmlbuilder-8.2.2.tgz", "integrity": "sha1-aSSGc0ELS6QuGmE2VR0pIjNap3M=", "dev": true, "optional": true diff --git a/package.json b/package.json index a8b70e7e..37ec3289 100644 --- a/package.json +++ b/package.json @@ -21,8 +21,9 @@ ], "scripts": { "build": "tsc", + "build:babel-test": "babel src/test/lib/decorators_test.ts --out-file test/lib/decrators-babel_test.js", "gen-docs": "typedoc --readme docs/_api/api-readme.md --tsconfig tsconfig_apidoc.json --mode modules --theme docs/_api/theme --excludeNotExported --excludePrivate --ignoreCompilerErrors --exclude '{**/*test*,**/node_modules/**,**/test/**}' --out ./docs/api src/**/*.ts", - "test": "npm run build && wct", + "test": "npm run build && npm run build:babel-test && wct", "checksize": "rollup -c ; rm lit-element.bundled.js", "format": "find src test | grep '\\.js$\\|\\.ts$' | xargs clang-format --style=file -i", "lint": "tslint --project ./", @@ -31,6 +32,10 @@ }, "author": "The Polymer Authors", "devDependencies": { + "@babel/cli": "^7.2.3", + "@babel/plugin-proposal-class-properties": "^7.2.3", + "@babel/plugin-proposal-decorators": "^7.2.3", + "@babel/plugin-transform-typescript": "^7.2.0", "@types/chai": "^4.0.1", "@types/mocha": "^5.2.4", "@webcomponents/shadycss": "^1.5.2", diff --git a/src/env.d.ts b/src/env.d.ts index f0941e6f..6d15d345 100644 --- a/src/env.d.ts +++ b/src/env.d.ts @@ -11,3 +11,19 @@ interface Window { ShadyCSS?: ShadyCSS; ShadyDOM?: ShadyDOM; } + +// From the TC39 Decorators proposal +interface ClassDescriptor { + kind: 'class'; + elements: ClassElement[]; +} + +// From the TC39 Decorators proposal +interface ClassElement { + kind: 'field'|'method'; + key: PropertyKey; + placement: 'static'|'prototype'|'own'; + initializer?: Function; + extras?; + finisher?; +} diff --git a/src/lib/decorators.ts b/src/lib/decorators.ts index 193c2bf2..0c4f43ba 100644 --- a/src/lib/decorators.ts +++ b/src/lib/decorators.ts @@ -41,13 +41,28 @@ export type Constructor = { * */ export const customElement = (tagName: string) => - (clazz: Constructor) => { - window.customElements.define(tagName, clazz); - // Cast as any because TS doesn't recognize the return type as being a - // subtype of the decorated class when clazz is typed as - // `Constructor` for some reason. `Constructor` - // is helpful to make sure the decorator is applied to elements however. - return clazz as any; + (classOrDescriptor: Constructor|ClassDescriptor) => { + if (typeof classOrDescriptor === 'function') { + const clazz = classOrDescriptor as Constructor; + // Legacy decorator + window.customElements.define(tagName, clazz); + // Cast as any because TS doesn't recognize the return type as being a + // subtype of the decorated class when clazz is typed as + // `Constructor` for some reason. + // `Constructor` is helpful to make sure the decorator is + // applied to elements however. + return clazz as any; + } + const {kind, elements} = classOrDescriptor; + console.assert(kind === 'class'); + return { + kind, + elements, + // This callback is called once the class is otherwise fully defined + finisher(clazz: Constructor) { + window.customElements.define(tagName, clazz); + } + }; }; /** @@ -55,10 +70,44 @@ export const customElement = (tagName: string) => * corresponding attribute value. A `PropertyDeclaration` may optionally be * supplied to configure property features. */ -export const property = (options?: PropertyDeclaration) => ( - proto: Object, name: PropertyKey) => { - (proto.constructor as typeof UpdatingElement).createProperty(name, options); -}; +export const property = (options?: PropertyDeclaration) => + (protoOrDescriptor: Object|ClassElement, name?: PropertyKey): any => { + if (name !== undefined) { + // Legacy decorator + (protoOrDescriptor.constructor as typeof UpdatingElement) + .createProperty(name!, options); + return; + } + const element = protoOrDescriptor as ClassElement; + console.assert(element.kind === 'field'); + // createProperty() takes care of defining the property, but we still must + // return some kind of descriptor, so return a descriptor for an unused + // prototype field. The finisher calls createProperty(). + return { + kind : 'field', + key : Symbol(), + placement : 'own', + descriptor : {}, + // When @babel/plugin-proposal-decorators implements initializers, do + // this instead of the initializer below. + // See: https://github.com/babel/babel/issues/9260 + // extras: [ + // { + // kind: 'initializer', + // placement: 'own', + // initializer: descriptor.initializer, + // } + // ], + initializer(this: any) { + if (typeof element.initializer === 'function') { + this[element.key] = element.initializer!.call(this); + } + }, + finisher(clazz: typeof UpdatingElement) { + clazz.createProperty(element.key, options); + } + }; + }; /** * A property decorator that converts a class property into a getter that @@ -81,12 +130,24 @@ export const queryAll = _query((target: NodeSelector, selector: string) => * against `target`. */ function _query(queryFn: (target: NodeSelector, selector: string) => T) { - return (selector: string) => (proto: any, propName: string) => { - Object.defineProperty(proto, propName, { + return (selector: string) => (protoOrDescriptor: any, name?: string): any => { + const descriptor = { get(this: LitElement) { return queryFn(this.renderRoot!, selector); }, enumerable : true, configurable : true, - }); + }; + if (name !== undefined) { + // Legacy decorator + Object.defineProperty(protoOrDescriptor, name, descriptor); + } else { + const element = protoOrDescriptor as ClassElement; + return { + kind : 'method', + placement : 'prototype', + key : element.key, + descriptor, + }; + } }; } @@ -117,7 +178,18 @@ function _query(queryFn: (target: NodeSelector, selector: string) => T) { * } */ export const eventOptions = (options: AddEventListenerOptions) => - (proto: any, name: string) => { - // This comment is here to fix a disagreement between formatter and linter - Object.assign(proto[name], options); + (protoOrDescriptor: any, name?: string) => { + if (name !== undefined) { + // Legacy decorator + Object.assign(protoOrDescriptor[name], options); + } else { + return { + ...protoOrDescriptor, + finisher(clazz: typeof UpdatingElement) { + Object.assign( + clazz.prototype[protoOrDescriptor.key as keyof UpdatingElement], + options); + }, + }; + } }; diff --git a/src/test/lib/decorators_test.ts b/src/test/lib/decorators_test.ts index 60899e7d..165db567 100644 --- a/src/test/lib/decorators_test.ts +++ b/src/test/lib/decorators_test.ts @@ -12,11 +12,12 @@ * http://polymer.github.io/PATENTS.txt */ -import {eventOptions} from '../../lib/decorators.js'; +import {eventOptions, property} from '../../lib/decorators.js'; import { customElement, html, LitElement, + PropertyValues, query, queryAll } from '../../lit-element.js'; @@ -95,6 +96,199 @@ suite('decorators', () => { }); }); + suite('@property', () => { + test('property options via decorator', async () => { + const hasChanged = (value: any, old: any) => + old === undefined || value > old; + const fromAttribute = (value: any) => parseInt(value); + const toAttribute = (value: any) => `${value}-attr`; + class E extends LitElement { + + @property({attribute : false}) noAttr = 'noAttr'; + @property({attribute : true}) atTr = 'attr'; + @property({attribute : 'custom', reflect: true}) + customAttr = 'customAttr'; + @property({hasChanged}) hasChanged = 10; + @property({converter : fromAttribute}) fromAttribute = 1; + @property({reflect : true, converter: {toAttribute}}) toAttribute = 1; + @property({ + attribute : 'all-attr', + hasChanged, + converter: {fromAttribute, toAttribute}, + reflect: true + }) + all = 10; + + updateCount = 0; + + update(changed: PropertyValues) { + this.updateCount++; + super.update(changed); + } + + render() { return html``; } + } + customElements.define(generateElementName(), E); + const el = new E(); + container.appendChild(el); + await el.updateComplete; + assert.equal(el.updateCount, 1); + assert.equal(el.noAttr, 'noAttr'); + assert.equal(el.atTr, 'attr'); + assert.equal(el.customAttr, 'customAttr'); + assert.equal(el.hasChanged, 10); + assert.equal(el.fromAttribute, 1); + assert.equal(el.toAttribute, 1); + assert.equal(el.getAttribute('toattribute'), '1-attr'); + assert.equal(el.all, 10); + assert.equal(el.getAttribute('all-attr'), '10-attr'); + el.setAttribute('noattr', 'noAttr2'); + el.setAttribute('attr', 'attr2'); + el.setAttribute('custom', 'customAttr2'); + el.setAttribute('fromattribute', '2attr'); + el.toAttribute = 2; + el.all = 5; + await el.updateComplete; + assert.equal(el.updateCount, 2); + assert.equal(el.noAttr, 'noAttr'); + assert.equal(el.atTr, 'attr2'); + assert.equal(el.customAttr, 'customAttr2'); + assert.equal(el.fromAttribute, 2); + assert.equal(el.toAttribute, 2); + assert.equal(el.getAttribute('toattribute'), '2-attr'); + assert.equal(el.all, 5); + el.all = 15; + await el.updateComplete; + assert.equal(el.updateCount, 3); + assert.equal(el.all, 15); + assert.equal(el.getAttribute('all-attr'), '15-attr'); + el.setAttribute('all-attr', '16-attr'); + await el.updateComplete; + assert.equal(el.updateCount, 4); + assert.equal(el.getAttribute('all-attr'), '16-attr'); + assert.equal(el.all, 16); + el.hasChanged = 5; + await el.updateComplete; + assert.equal(el.hasChanged, 5); + assert.equal(el.updateCount, 4); + el.hasChanged = 15; + await el.updateComplete; + assert.equal(el.hasChanged, 15); + assert.equal(el.updateCount, 5); + el.setAttribute('all-attr', '5-attr'); + await el.updateComplete; + assert.equal(el.all, 5); + assert.equal(el.updateCount, 5); + el.all = 15; + await el.updateComplete; + assert.equal(el.all, 15); + assert.equal(el.updateCount, 6); + }); + + test('can mix property options via decorator and via getter', async () => { + const hasChanged = (value: any, old: any) => + old === undefined || value > old; + const fromAttribute = (value: any) => parseInt(value); + const toAttribute = (value: any) => `${value}-attr`; + class E extends LitElement { + + @property({hasChanged}) hasChanged = 10; + @property({converter : fromAttribute}) fromAttribute = 1; + @property({reflect : true, converter: {toAttribute}}) toAttribute = 1; + @property({ + attribute : 'all-attr', + hasChanged, + converter: {fromAttribute, toAttribute}, + reflect: true + }) + all = 10; + + updateCount = 0; + + static get properties() { + return { + noAttr : {attribute : false}, + atTr : {attribute : true}, + customAttr : {attribute : 'custom', reflect : true}, + }; + } + + noAttr: string|undefined; + atTr: string|undefined; + customAttr: string|undefined; + + constructor() { + super(); + this.noAttr = 'noAttr'; + this.atTr = 'attr'; + this.customAttr = 'customAttr'; + } + + update(changed: PropertyValues) { + this.updateCount++; + super.update(changed); + } + + render() { return html``; } + } + customElements.define(generateElementName(), E); + const el = new E(); + container.appendChild(el); + await el.updateComplete; + assert.equal(el.updateCount, 1); + assert.equal(el.noAttr, 'noAttr'); + assert.equal(el.atTr, 'attr'); + assert.equal(el.customAttr, 'customAttr'); + assert.equal(el.hasChanged, 10); + assert.equal(el.fromAttribute, 1); + assert.equal(el.toAttribute, 1); + assert.equal(el.getAttribute('toattribute'), '1-attr'); + assert.equal(el.all, 10); + assert.equal(el.getAttribute('all-attr'), '10-attr'); + el.setAttribute('noattr', 'noAttr2'); + el.setAttribute('attr', 'attr2'); + el.setAttribute('custom', 'customAttr2'); + el.setAttribute('fromattribute', '2attr'); + el.toAttribute = 2; + el.all = 5; + await el.updateComplete; + assert.equal(el.updateCount, 2); + assert.equal(el.noAttr, 'noAttr'); + assert.equal(el.atTr, 'attr2'); + assert.equal(el.customAttr, 'customAttr2'); + assert.equal(el.fromAttribute, 2); + assert.equal(el.toAttribute, 2); + assert.equal(el.getAttribute('toattribute'), '2-attr'); + assert.equal(el.all, 5); + el.all = 15; + await el.updateComplete; + assert.equal(el.updateCount, 3); + assert.equal(el.all, 15); + assert.equal(el.getAttribute('all-attr'), '15-attr'); + el.setAttribute('all-attr', '16-attr'); + await el.updateComplete; + assert.equal(el.updateCount, 4); + assert.equal(el.getAttribute('all-attr'), '16-attr'); + assert.equal(el.all, 16); + el.hasChanged = 5; + await el.updateComplete; + assert.equal(el.hasChanged, 5); + assert.equal(el.updateCount, 4); + el.hasChanged = 15; + await el.updateComplete; + assert.equal(el.hasChanged, 15); + assert.equal(el.updateCount, 5); + el.setAttribute('all-attr', '5-attr'); + await el.updateComplete; + assert.equal(el.all, 5); + assert.equal(el.updateCount, 5); + el.all = 15; + await el.updateComplete; + assert.equal(el.all, 15); + assert.equal(el.updateCount, 6); + }); + }); + suite('@query', () => { @customElement(generateElementName() as keyof HTMLElementTagNameMap) class C extends LitElement { diff --git a/src/test/lit-element_test.ts b/src/test/lit-element_test.ts index 01a93799..1eaed676 100644 --- a/src/test/lit-element_test.ts +++ b/src/test/lit-element_test.ts @@ -519,197 +519,6 @@ suite('LitElement', () => { assert.equal(el.getAttribute('obj'), '{"obj":3}'); }); - test('property options via decorator', async () => { - const hasChanged = (value: any, old: any) => - old === undefined || value > old; - const fromAttribute = (value: any) => parseInt(value); - const toAttribute = (value: any) => `${value}-attr`; - class E extends LitElement { - - @property({attribute : false}) noAttr = 'noAttr'; - @property({attribute : true}) atTr = 'attr'; - @property({attribute : 'custom', reflect: true}) - customAttr = 'customAttr'; - @property({hasChanged}) hasChanged = 10; - @property({converter : fromAttribute}) fromAttribute = 1; - @property({reflect : true, converter: {toAttribute}}) toAttribute = 1; - @property({ - attribute : 'all-attr', - hasChanged, - converter: {fromAttribute, toAttribute}, - reflect: true - }) - all = 10; - - updateCount = 0; - - update(changed: PropertyValues) { - this.updateCount++; - super.update(changed); - } - - render() { return html``; } - } - customElements.define(generateElementName(), E); - const el = new E(); - container.appendChild(el); - await el.updateComplete; - assert.equal(el.updateCount, 1); - assert.equal(el.noAttr, 'noAttr'); - assert.equal(el.atTr, 'attr'); - assert.equal(el.customAttr, 'customAttr'); - assert.equal(el.hasChanged, 10); - assert.equal(el.fromAttribute, 1); - assert.equal(el.toAttribute, 1); - assert.equal(el.getAttribute('toattribute'), '1-attr'); - assert.equal(el.all, 10); - assert.equal(el.getAttribute('all-attr'), '10-attr'); - el.setAttribute('noattr', 'noAttr2'); - el.setAttribute('attr', 'attr2'); - el.setAttribute('custom', 'customAttr2'); - el.setAttribute('fromattribute', '2attr'); - el.toAttribute = 2; - el.all = 5; - await el.updateComplete; - assert.equal(el.updateCount, 2); - assert.equal(el.noAttr, 'noAttr'); - assert.equal(el.atTr, 'attr2'); - assert.equal(el.customAttr, 'customAttr2'); - assert.equal(el.fromAttribute, 2); - assert.equal(el.toAttribute, 2); - assert.equal(el.getAttribute('toattribute'), '2-attr'); - assert.equal(el.all, 5); - el.all = 15; - await el.updateComplete; - assert.equal(el.updateCount, 3); - assert.equal(el.all, 15); - assert.equal(el.getAttribute('all-attr'), '15-attr'); - el.setAttribute('all-attr', '16-attr'); - await el.updateComplete; - assert.equal(el.updateCount, 4); - assert.equal(el.getAttribute('all-attr'), '16-attr'); - assert.equal(el.all, 16); - el.hasChanged = 5; - await el.updateComplete; - assert.equal(el.hasChanged, 5); - assert.equal(el.updateCount, 4); - el.hasChanged = 15; - await el.updateComplete; - assert.equal(el.hasChanged, 15); - assert.equal(el.updateCount, 5); - el.setAttribute('all-attr', '5-attr'); - await el.updateComplete; - assert.equal(el.all, 5); - assert.equal(el.updateCount, 5); - el.all = 15; - await el.updateComplete; - assert.equal(el.all, 15); - assert.equal(el.updateCount, 6); - }); - - test('can mix property options via decorator and via getter', async () => { - const hasChanged = (value: any, old: any) => - old === undefined || value > old; - const fromAttribute = (value: any) => parseInt(value); - const toAttribute = (value: any) => `${value}-attr`; - class E extends LitElement { - - @property({hasChanged}) hasChanged = 10; - @property({converter : fromAttribute}) fromAttribute = 1; - @property({reflect : true, converter: {toAttribute}}) toAttribute = 1; - @property({ - attribute : 'all-attr', - hasChanged, - converter: {fromAttribute, toAttribute}, - reflect: true - }) - all = 10; - - updateCount = 0; - - static get properties() { - return { - noAttr : {attribute : false}, - atTr : {attribute : true}, - customAttr : {attribute : 'custom', reflect : true}, - }; - } - - noAttr: string|undefined; - atTr: string|undefined; - customAttr: string|undefined; - - constructor() { - super(); - this.noAttr = 'noAttr'; - this.atTr = 'attr'; - this.customAttr = 'customAttr'; - } - - update(changed: PropertyValues) { - this.updateCount++; - super.update(changed); - } - - render() { return html``; } - } - customElements.define(generateElementName(), E); - const el = new E(); - container.appendChild(el); - await el.updateComplete; - assert.equal(el.updateCount, 1); - assert.equal(el.noAttr, 'noAttr'); - assert.equal(el.atTr, 'attr'); - assert.equal(el.customAttr, 'customAttr'); - assert.equal(el.hasChanged, 10); - assert.equal(el.fromAttribute, 1); - assert.equal(el.toAttribute, 1); - assert.equal(el.getAttribute('toattribute'), '1-attr'); - assert.equal(el.all, 10); - assert.equal(el.getAttribute('all-attr'), '10-attr'); - el.setAttribute('noattr', 'noAttr2'); - el.setAttribute('attr', 'attr2'); - el.setAttribute('custom', 'customAttr2'); - el.setAttribute('fromattribute', '2attr'); - el.toAttribute = 2; - el.all = 5; - await el.updateComplete; - assert.equal(el.updateCount, 2); - assert.equal(el.noAttr, 'noAttr'); - assert.equal(el.atTr, 'attr2'); - assert.equal(el.customAttr, 'customAttr2'); - assert.equal(el.fromAttribute, 2); - assert.equal(el.toAttribute, 2); - assert.equal(el.getAttribute('toattribute'), '2-attr'); - assert.equal(el.all, 5); - el.all = 15; - await el.updateComplete; - assert.equal(el.updateCount, 3); - assert.equal(el.all, 15); - assert.equal(el.getAttribute('all-attr'), '15-attr'); - el.setAttribute('all-attr', '16-attr'); - await el.updateComplete; - assert.equal(el.updateCount, 4); - assert.equal(el.getAttribute('all-attr'), '16-attr'); - assert.equal(el.all, 16); - el.hasChanged = 5; - await el.updateComplete; - assert.equal(el.hasChanged, 5); - assert.equal(el.updateCount, 4); - el.hasChanged = 15; - await el.updateComplete; - assert.equal(el.hasChanged, 15); - assert.equal(el.updateCount, 5); - el.setAttribute('all-attr', '5-attr'); - await el.updateComplete; - assert.equal(el.all, 5); - assert.equal(el.updateCount, 5); - el.all = 15; - await el.updateComplete; - assert.equal(el.all, 15); - assert.equal(el.updateCount, 6); - }); - test('attributes deserialize from html', async () => { const fromAttribute = (value: any) => parseInt(value); const toAttributeOnly = (value: any) => diff --git a/test/runner.html b/test/runner.html index 521ef661..d242c224 100644 --- a/test/runner.html +++ b/test/runner.html @@ -19,5 +19,6 @@ +