Commit 6b91c4a7 authored by Rosanny Sihombing's avatar Rosanny Sihombing
Browse files

delete and ignore node_modules

parent 22482a26
No related merge requests found
Showing with 0 additions and 797 deletions
+0 -797
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = rewriteThis;
function rewriteThis(programPath) {
programPath.traverse(rewriteThisVisitor);
}
const rewriteThisVisitor = {
ThisExpression(path) {
path.replaceWith(path.scope.buildUndefinedNode());
},
Function(path) {
if (!path.isArrowFunctionExpression()) path.skip();
},
ClassProperty(path) {
path.skip();
},
ClassPrivateProperty(path) {
path.skip();
}
};
\ No newline at end of file
{
"_from": "@babel/helper-module-transforms@^7.1.0",
"_id": "@babel/helper-module-transforms@7.7.0",
"_inBundle": false,
"_integrity": "sha512-rXEefBuheUYQyX4WjV19tuknrJFwyKw0HgzRwbkyTbB+Dshlq7eqkWbyjzToLrMZk/5wKVKdWFluiAsVkHXvuQ==",
"_location": "/@babel/helper-module-transforms",
"_phantomChildren": {},
"_requested": {
"type": "range",
"registry": true,
"raw": "@babel/helper-module-transforms@^7.1.0",
"name": "@babel/helper-module-transforms",
"escapedName": "@babel%2fhelper-module-transforms",
"scope": "@babel",
"rawSpec": "^7.1.0",
"saveSpec": null,
"fetchSpec": "^7.1.0"
},
"_requiredBy": [
"/@babel/plugin-transform-modules-amd",
"/@babel/plugin-transform-modules-commonjs",
"/@babel/plugin-transform-modules-umd"
],
"_resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.7.0.tgz",
"_shasum": "154a69f0c5b8fd4d39e49750ff7ac4faa3f36786",
"_spec": "@babel/helper-module-transforms@^7.1.0",
"_where": "C:\\Work\\OneDrive - bwstaff\\M4_Lab\\TV3\\NewVersion01\\LAFJLBmf939XYm5gj\\dev\\node_modules\\@babel\\plugin-transform-modules-amd",
"author": {
"name": "Logan Smyth",
"email": "loganfsmyth@gmail.com"
},
"bundleDependencies": false,
"dependencies": {
"@babel/helper-module-imports": "^7.7.0",
"@babel/helper-simple-access": "^7.7.0",
"@babel/helper-split-export-declaration": "^7.7.0",
"@babel/template": "^7.7.0",
"@babel/types": "^7.7.0",
"lodash": "^4.17.13"
},
"deprecated": false,
"description": "Babel helper functions for implementing ES6 module transformations",
"gitHead": "97faa83953cb87e332554fa559a4956d202343ea",
"homepage": "https://babeljs.io/",
"license": "MIT",
"main": "lib/index.js",
"name": "@babel/helper-module-transforms",
"publishConfig": {
"access": "public"
},
"repository": {
"type": "git",
"url": "https://github.com/babel/babel/tree/master/packages/babel-helper-module-transforms"
},
"version": "7.7.0"
}
MIT License
Copyright (c) 2014-present Sebastian McKenzie and other contributors
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# @babel/helper-optimise-call-expression
> Helper function to optimise call expression
See our website [@babel/helper-optimise-call-expression](https://babeljs.io/docs/en/next/babel-helper-optimise-call-expression.html) for more information.
## Install
Using npm:
```sh
npm install --save-dev @babel/helper-optimise-call-expression
```
or using yarn:
```sh
yarn add @babel/helper-optimise-call-expression --dev
```
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = _default;
var t = _interopRequireWildcard(require("@babel/types"));
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; if (obj != null) { var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
function _default(callee, thisNode, args) {
if (args.length === 1 && t.isSpreadElement(args[0]) && t.isIdentifier(args[0].argument, {
name: "arguments"
})) {
return t.callExpression(t.memberExpression(callee, t.identifier("apply")), [thisNode, args[0].argument]);
} else {
return t.callExpression(t.memberExpression(callee, t.identifier("call")), [thisNode, ...args]);
}
}
\ No newline at end of file
{
"_from": "@babel/helper-optimise-call-expression@^7.7.0",
"_id": "@babel/helper-optimise-call-expression@7.7.0",
"_inBundle": false,
"_integrity": "sha512-48TeqmbazjNU/65niiiJIJRc5JozB8acui1OS7bSd6PgxfuovWsvjfWSzlgx+gPFdVveNzUdpdIg5l56Pl5jqg==",
"_location": "/@babel/helper-optimise-call-expression",
"_phantomChildren": {},
"_requested": {
"type": "range",
"registry": true,
"raw": "@babel/helper-optimise-call-expression@^7.7.0",
"name": "@babel/helper-optimise-call-expression",
"escapedName": "@babel%2fhelper-optimise-call-expression",
"scope": "@babel",
"rawSpec": "^7.7.0",
"saveSpec": null,
"fetchSpec": "^7.7.0"
},
"_requiredBy": [
"/@babel/helper-create-class-features-plugin",
"/@babel/helper-replace-supers",
"/@babel/plugin-transform-classes"
],
"_resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.7.0.tgz",
"_shasum": "4f66a216116a66164135dc618c5d8b7a959f9365",
"_spec": "@babel/helper-optimise-call-expression@^7.7.0",
"_where": "C:\\Work\\OneDrive - bwstaff\\M4_Lab\\TV3\\NewVersion01\\LAFJLBmf939XYm5gj\\dev\\node_modules\\@babel\\helper-create-class-features-plugin",
"bundleDependencies": false,
"dependencies": {
"@babel/types": "^7.7.0"
},
"deprecated": false,
"description": "Helper function to optimise call expression",
"gitHead": "97faa83953cb87e332554fa559a4956d202343ea",
"license": "MIT",
"main": "lib/index.js",
"name": "@babel/helper-optimise-call-expression",
"publishConfig": {
"access": "public"
},
"repository": {
"type": "git",
"url": "https://github.com/babel/babel/tree/master/packages/babel-helper-optimise-call-expression"
},
"version": "7.7.0"
}
MIT License
Copyright (c) 2014-2018 Sebastian McKenzie <sebmck@gmail.com>
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# @babel/helper-plugin-utils
> General utilities for plugins to use
See our website [@babel/helper-plugin-utils](https://babeljs.io/docs/en/next/babel-helper-plugin-utils.html) for more information.
## Install
Using npm:
```sh
npm install --save-dev @babel/helper-plugin-utils
```
or using yarn:
```sh
yarn add @babel/helper-plugin-utils --dev
```
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.declare = declare;
function declare(builder) {
return (api, options, dirname) => {
if (!api.assertVersion) {
api = Object.assign(copyApiObject(api), {
assertVersion(range) {
throwVersionError(range, api.version);
}
});
}
return builder(api, options || {}, dirname);
};
}
function copyApiObject(api) {
let proto = null;
if (typeof api.version === "string" && /^7\./.test(api.version)) {
proto = Object.getPrototypeOf(api);
if (proto && (!has(proto, "version") || !has(proto, "transform") || !has(proto, "template") || !has(proto, "types"))) {
proto = null;
}
}
return Object.assign({}, proto, api);
}
function has(obj, key) {
return Object.prototype.hasOwnProperty.call(obj, key);
}
function throwVersionError(range, version) {
if (typeof range === "number") {
if (!Number.isInteger(range)) {
throw new Error("Expected string or integer value.");
}
range = `^${range}.0.0-0`;
}
if (typeof range !== "string") {
throw new Error("Expected string or integer value.");
}
const limit = Error.stackTraceLimit;
if (typeof limit === "number" && limit < 25) {
Error.stackTraceLimit = 25;
}
let err;
if (version.slice(0, 2) === "7.") {
err = new Error(`Requires Babel "^7.0.0-beta.41", but was loaded with "${version}". ` + `You'll need to update your @babel/core version.`);
} else {
err = new Error(`Requires Babel "${range}", but was loaded with "${version}". ` + `If you are sure you have a compatible version of @babel/core, ` + `it is likely that something in your build process is loading the ` + `wrong version. Inspect the stack trace of this error to look for ` + `the first entry that doesn't mention "@babel/core" or "babel-core" ` + `to see what is calling Babel.`);
}
if (typeof limit === "number") {
Error.stackTraceLimit = limit;
}
throw Object.assign(err, {
code: "BABEL_VERSION_UNSUPPORTED",
version,
range
});
}
\ No newline at end of file
{
"_from": "@babel/helper-plugin-utils@^7.0.0",
"_id": "@babel/helper-plugin-utils@7.0.0",
"_inBundle": false,
"_integrity": "sha512-CYAOUCARwExnEixLdB6sDm2dIJ/YgEAKDM1MOeMeZu9Ld/bDgVo8aiWrXwcY7OBh+1Ea2uUcVRcxKk0GJvW7QA==",
"_location": "/@babel/helper-plugin-utils",
"_phantomChildren": {},
"_requested": {
"type": "range",
"registry": true,
"raw": "@babel/helper-plugin-utils@^7.0.0",
"name": "@babel/helper-plugin-utils",
"escapedName": "@babel%2fhelper-plugin-utils",
"scope": "@babel",
"rawSpec": "^7.0.0",
"saveSpec": null,
"fetchSpec": "^7.0.0"
},
"_requiredBy": [
"/@babel/helper-create-class-features-plugin",
"/@babel/plugin-proposal-async-generator-functions",
"/@babel/plugin-proposal-class-properties",
"/@babel/plugin-proposal-decorators",
"/@babel/plugin-proposal-json-strings",
"/@babel/plugin-proposal-object-rest-spread",
"/@babel/plugin-proposal-optional-catch-binding",
"/@babel/plugin-proposal-unicode-property-regex",
"/@babel/plugin-syntax-async-generators",
"/@babel/plugin-syntax-decorators",
"/@babel/plugin-syntax-dynamic-import",
"/@babel/plugin-syntax-json-strings",
"/@babel/plugin-syntax-jsx",
"/@babel/plugin-syntax-object-rest-spread",
"/@babel/plugin-syntax-optional-catch-binding",
"/@babel/plugin-transform-arrow-functions",
"/@babel/plugin-transform-async-to-generator",
"/@babel/plugin-transform-block-scoped-functions",
"/@babel/plugin-transform-block-scoping",
"/@babel/plugin-transform-classes",
"/@babel/plugin-transform-computed-properties",
"/@babel/plugin-transform-destructuring",
"/@babel/plugin-transform-dotall-regex",
"/@babel/plugin-transform-duplicate-keys",
"/@babel/plugin-transform-exponentiation-operator",
"/@babel/plugin-transform-for-of",
"/@babel/plugin-transform-function-name",
"/@babel/plugin-transform-literals",
"/@babel/plugin-transform-modules-amd",
"/@babel/plugin-transform-modules-commonjs",
"/@babel/plugin-transform-modules-systemjs",
"/@babel/plugin-transform-modules-umd",
"/@babel/plugin-transform-new-target",
"/@babel/plugin-transform-object-super",
"/@babel/plugin-transform-parameters",
"/@babel/plugin-transform-runtime",
"/@babel/plugin-transform-shorthand-properties",
"/@babel/plugin-transform-spread",
"/@babel/plugin-transform-sticky-regex",
"/@babel/plugin-transform-template-literals",
"/@babel/plugin-transform-typeof-symbol",
"/@babel/plugin-transform-unicode-regex",
"/@babel/preset-env"
],
"_resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.0.0.tgz",
"_shasum": "bbb3fbee98661c569034237cc03967ba99b4f250",
"_spec": "@babel/helper-plugin-utils@^7.0.0",
"_where": "C:\\Work\\OneDrive - bwstaff\\M4_Lab\\TV3\\NewVersion01\\LAFJLBmf939XYm5gj\\dev\\node_modules\\@babel\\plugin-proposal-class-properties",
"author": {
"name": "Logan Smyth",
"email": "loganfsmyth@gmail.com"
},
"bundleDependencies": false,
"deprecated": false,
"description": "General utilities for plugins to use",
"homepage": "https://babeljs.io/",
"license": "MIT",
"main": "lib/index.js",
"name": "@babel/helper-plugin-utils",
"repository": {
"type": "git",
"url": "https://github.com/babel/babel/tree/master/packages/babel-helper-plugin-utils"
},
"version": "7.0.0"
}
export function declare(builder) {
return (api, options, dirname) => {
if (!api.assertVersion) {
// Inject a custom version of 'assertVersion' for Babel 6 and early
// versions of Babel 7's beta that didn't have it.
api = Object.assign(copyApiObject(api), {
assertVersion(range) {
throwVersionError(range, api.version);
},
});
}
return builder(api, options || {}, dirname);
};
}
function copyApiObject(api) {
// Babel >= 7 <= beta.41 passed the API as a new object that had
// babel/core as the prototype. While slightly faster, it also
// means that the Object.assign copy below fails. Rather than
// keep complexity, the Babel 6 behavior has been reverted and this
// normalizes all that for Babel 7.
let proto = null;
if (typeof api.version === "string" && /^7\./.test(api.version)) {
proto = Object.getPrototypeOf(api);
if (
proto &&
(!has(proto, "version") ||
!has(proto, "transform") ||
!has(proto, "template") ||
!has(proto, "types"))
) {
proto = null;
}
}
return {
...proto,
...api,
};
}
function has(obj, key) {
return Object.prototype.hasOwnProperty.call(obj, key);
}
function throwVersionError(range, version) {
if (typeof range === "number") {
if (!Number.isInteger(range)) {
throw new Error("Expected string or integer value.");
}
range = `^${range}.0.0-0`;
}
if (typeof range !== "string") {
throw new Error("Expected string or integer value.");
}
const limit = Error.stackTraceLimit;
if (typeof limit === "number" && limit < 25) {
// Bump up the limit if needed so that users are more likely
// to be able to see what is calling Babel.
Error.stackTraceLimit = 25;
}
let err;
if (version.slice(0, 2) === "7.") {
err = new Error(
`Requires Babel "^7.0.0-beta.41", but was loaded with "${version}". ` +
`You'll need to update your @babel/core version.`,
);
} else {
err = new Error(
`Requires Babel "${range}", but was loaded with "${version}". ` +
`If you are sure you have a compatible version of @babel/core, ` +
`it is likely that something in your build process is loading the ` +
`wrong version. Inspect the stack trace of this error to look for ` +
`the first entry that doesn't mention "@babel/core" or "babel-core" ` +
`to see what is calling Babel.`,
);
}
if (typeof limit === "number") {
Error.stackTraceLimit = limit;
}
throw Object.assign(
err,
({
code: "BABEL_VERSION_UNSUPPORTED",
version,
range,
}: any),
);
}
MIT License
Copyright (c) 2014-present Sebastian McKenzie and other contributors
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# @babel/helper-regex
> Helper function to check for literal RegEx
See our website [@babel/helper-regex](https://babeljs.io/docs/en/next/babel-helper-regex.html) for more information.
## Install
Using npm:
```sh
npm install --save-dev @babel/helper-regex
```
or using yarn:
```sh
yarn add @babel/helper-regex --dev
```
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.is = is;
exports.pullFlag = pullFlag;
function _pull() {
const data = _interopRequireDefault(require("lodash/pull"));
_pull = function () {
return data;
};
return data;
}
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
function is(node, flag) {
return node.type === "RegExpLiteral" && node.flags.indexOf(flag) >= 0;
}
function pullFlag(node, flag) {
const flags = node.flags.split("");
if (node.flags.indexOf(flag) < 0) return;
(0, _pull().default)(flags, flag);
node.flags = flags.join("");
}
\ No newline at end of file
{
"_from": "@babel/helper-regex@^7.4.4",
"_id": "@babel/helper-regex@7.5.5",
"_inBundle": false,
"_integrity": "sha512-CkCYQLkfkiugbRDO8eZn6lRuR8kzZoGXCg3149iTk5se7g6qykSpy3+hELSwquhu+TgHn8nkLiBwHvNX8Hofcw==",
"_location": "/@babel/helper-regex",
"_phantomChildren": {},
"_requested": {
"type": "range",
"registry": true,
"raw": "@babel/helper-regex@^7.4.4",
"name": "@babel/helper-regex",
"escapedName": "@babel%2fhelper-regex",
"scope": "@babel",
"rawSpec": "^7.4.4",
"saveSpec": null,
"fetchSpec": "^7.4.4"
},
"_requiredBy": [
"/@babel/helper-create-regexp-features-plugin",
"/@babel/plugin-transform-sticky-regex"
],
"_resolved": "https://registry.npmjs.org/@babel/helper-regex/-/helper-regex-7.5.5.tgz",
"_shasum": "0aa6824f7100a2e0e89c1527c23936c152cab351",
"_spec": "@babel/helper-regex@^7.4.4",
"_where": "C:\\Work\\OneDrive - bwstaff\\M4_Lab\\TV3\\NewVersion01\\LAFJLBmf939XYm5gj\\dev\\node_modules\\@babel\\helper-create-regexp-features-plugin",
"bundleDependencies": false,
"dependencies": {
"lodash": "^4.17.13"
},
"deprecated": false,
"description": "Helper function to check for literal RegEx",
"gitHead": "0407f034f09381b95e9cabefbf6b176c76485a43",
"license": "MIT",
"main": "lib/index.js",
"name": "@babel/helper-regex",
"publishConfig": {
"access": "public"
},
"repository": {
"type": "git",
"url": "https://github.com/babel/babel/tree/master/packages/babel-helper-regex"
},
"version": "7.5.5"
}
MIT License
Copyright (c) 2014-present Sebastian McKenzie and other contributors
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# @babel/helper-remap-async-to-generator
> Helper function to remap async functions to generators
See our website [@babel/helper-remap-async-to-generator](https://babeljs.io/docs/en/next/babel-helper-remap-async-to-generator.html) for more information.
## Install
Using npm:
```sh
npm install --save-dev @babel/helper-remap-async-to-generator
```
or using yarn:
```sh
yarn add @babel/helper-remap-async-to-generator --dev
```
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = _default;
var _helperWrapFunction = _interopRequireDefault(require("@babel/helper-wrap-function"));
var _helperAnnotateAsPure = _interopRequireDefault(require("@babel/helper-annotate-as-pure"));
var t = _interopRequireWildcard(require("@babel/types"));
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; if (obj != null) { var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
const awaitVisitor = {
Function(path) {
path.skip();
},
AwaitExpression(path, {
wrapAwait
}) {
const argument = path.get("argument");
if (path.parentPath.isYieldExpression()) {
path.replaceWith(argument.node);
return;
}
path.replaceWith(t.yieldExpression(wrapAwait ? t.callExpression(t.cloneNode(wrapAwait), [argument.node]) : argument.node));
}
};
function _default(path, helpers) {
path.traverse(awaitVisitor, {
wrapAwait: helpers.wrapAwait
});
const isIIFE = checkIsIIFE(path);
path.node.async = false;
path.node.generator = true;
(0, _helperWrapFunction.default)(path, t.cloneNode(helpers.wrapAsync));
const isProperty = path.isObjectMethod() || path.isClassMethod() || path.parentPath.isObjectProperty() || path.parentPath.isClassProperty();
if (!isProperty && !isIIFE && path.isExpression()) {
(0, _helperAnnotateAsPure.default)(path);
}
function checkIsIIFE(path) {
if (path.parentPath.isCallExpression({
callee: path.node
})) {
return true;
}
const {
parentPath
} = path;
if (parentPath.isMemberExpression() && t.isIdentifier(parentPath.node.property, {
name: "bind"
})) {
const {
parentPath: bindCall
} = parentPath;
return bindCall.isCallExpression() && bindCall.node.arguments.length === 1 && t.isThisExpression(bindCall.node.arguments[0]) && bindCall.parentPath.isCallExpression({
callee: bindCall.node
});
}
return false;
}
}
\ No newline at end of file
{
"_from": "@babel/helper-remap-async-to-generator@^7.7.0",
"_id": "@babel/helper-remap-async-to-generator@7.7.0",
"_inBundle": false,
"_integrity": "sha512-pHx7RN8X0UNHPB/fnuDnRXVZ316ZigkO8y8D835JlZ2SSdFKb6yH9MIYRU4fy/KPe5sPHDFOPvf8QLdbAGGiyw==",
"_location": "/@babel/helper-remap-async-to-generator",
"_phantomChildren": {},
"_requested": {
"type": "range",
"registry": true,
"raw": "@babel/helper-remap-async-to-generator@^7.7.0",
"name": "@babel/helper-remap-async-to-generator",
"escapedName": "@babel%2fhelper-remap-async-to-generator",
"scope": "@babel",
"rawSpec": "^7.7.0",
"saveSpec": null,
"fetchSpec": "^7.7.0"
},
"_requiredBy": [
"/@babel/plugin-proposal-async-generator-functions",
"/@babel/plugin-transform-async-to-generator"
],
"_resolved": "https://registry.npmjs.org/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.7.0.tgz",
"_shasum": "4d69ec653e8bff5bce62f5d33fc1508f223c75a7",
"_spec": "@babel/helper-remap-async-to-generator@^7.7.0",
"_where": "C:\\Work\\OneDrive - bwstaff\\M4_Lab\\TV3\\NewVersion01\\LAFJLBmf939XYm5gj\\dev\\node_modules\\@babel\\plugin-proposal-async-generator-functions",
"bundleDependencies": false,
"dependencies": {
"@babel/helper-annotate-as-pure": "^7.7.0",
"@babel/helper-wrap-function": "^7.7.0",
"@babel/template": "^7.7.0",
"@babel/traverse": "^7.7.0",
"@babel/types": "^7.7.0"
},
"deprecated": false,
"description": "Helper function to remap async functions to generators",
"gitHead": "97faa83953cb87e332554fa559a4956d202343ea",
"license": "MIT",
"main": "lib/index.js",
"name": "@babel/helper-remap-async-to-generator",
"publishConfig": {
"access": "public"
},
"repository": {
"type": "git",
"url": "https://github.com/babel/babel/tree/master/packages/babel-helper-remap-async-to-generator"
},
"version": "7.7.0"
}
MIT License
Copyright (c) 2014-present Sebastian McKenzie and other contributors
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment