diff options
| author | littleblack111 <littleblack11111@gmail.com> | 2023-10-14 15:31:11 +0800 |
|---|---|---|
| committer | littleblack111 <littleblack11111@gmail.com> | 2023-10-14 15:31:11 +0800 |
| commit | aa773172311dcada759dfbaac485f4bc6e00bc21 (patch) | |
| tree | ca6d9a5eff3ab8f689f9acb4f0df791d9486813d /node_modules/@babel/plugin-syntax-import-attributes/lib | |
| parent | c5a5384e846f242e901e859fe600d695d8990a9a (diff) | |
added babel
Diffstat (limited to 'node_modules/@babel/plugin-syntax-import-attributes/lib')
| -rw-r--r-- | node_modules/@babel/plugin-syntax-import-attributes/lib/index.js | 31 | ||||
| -rw-r--r-- | node_modules/@babel/plugin-syntax-import-attributes/lib/index.js.map | 1 |
2 files changed, 32 insertions, 0 deletions
diff --git a/node_modules/@babel/plugin-syntax-import-attributes/lib/index.js b/node_modules/@babel/plugin-syntax-import-attributes/lib/index.js new file mode 100644 index 00000000..6e78b9a0 --- /dev/null +++ b/node_modules/@babel/plugin-syntax-import-attributes/lib/index.js @@ -0,0 +1,31 @@ +"use strict"; + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.default = void 0; +var _helperPluginUtils = require("@babel/helper-plugin-utils"); +var _default = (0, _helperPluginUtils.declare)((api, { + deprecatedAssertSyntax +}) => { + api.assertVersion("^7.22.0"); + if (deprecatedAssertSyntax != null && typeof deprecatedAssertSyntax !== "boolean") { + throw new Error("'deprecatedAssertSyntax' must be a boolean, if specified."); + } + return { + name: "syntax-import-attributes", + manipulateOptions({ + parserOpts, + generatorOpts + }) { + var _generatorOpts$import; + (_generatorOpts$import = generatorOpts.importAttributesKeyword) != null ? _generatorOpts$import : generatorOpts.importAttributesKeyword = "with"; + parserOpts.plugins.push(["importAttributes", { + deprecatedAssertSyntax: Boolean(deprecatedAssertSyntax) + }]); + } + }; +}); +exports.default = _default; + +//# sourceMappingURL=index.js.map diff --git a/node_modules/@babel/plugin-syntax-import-attributes/lib/index.js.map b/node_modules/@babel/plugin-syntax-import-attributes/lib/index.js.map new file mode 100644 index 00000000..678a35c5 --- /dev/null +++ b/node_modules/@babel/plugin-syntax-import-attributes/lib/index.js.map @@ -0,0 +1 @@ +{"version":3,"names":["_helperPluginUtils","require","_default","declare","api","deprecatedAssertSyntax","assertVersion","Error","name","manipulateOptions","parserOpts","generatorOpts","_generatorOpts$import","importAttributesKeyword","plugins","push","Boolean","exports","default"],"sources":["../src/index.ts"],"sourcesContent":["import { declare } from \"@babel/helper-plugin-utils\";\n\nexport interface Options {\n deprecatedAssertSyntax?: boolean;\n}\n\nexport default declare((api, { deprecatedAssertSyntax }: Options) => {\n api.assertVersion(\"^7.22.0\");\n\n if (\n deprecatedAssertSyntax != null &&\n typeof deprecatedAssertSyntax !== \"boolean\"\n ) {\n throw new Error(\n \"'deprecatedAssertSyntax' must be a boolean, if specified.\",\n );\n }\n\n return {\n name: \"syntax-import-attributes\",\n\n manipulateOptions({ parserOpts, generatorOpts }) {\n generatorOpts.importAttributesKeyword ??= \"with\";\n parserOpts.plugins.push([\n \"importAttributes\",\n { deprecatedAssertSyntax: Boolean(deprecatedAssertSyntax) },\n ]);\n },\n };\n});\n"],"mappings":";;;;;;AAAA,IAAAA,kBAAA,GAAAC,OAAA;AAAqD,IAAAC,QAAA,GAMtC,IAAAC,0BAAO,EAAC,CAACC,GAAG,EAAE;EAAEC;AAAgC,CAAC,KAAK;EACnED,GAAG,CAACE,aAAa,CAAC,SAAS,CAAC;EAE5B,IACED,sBAAsB,IAAI,IAAI,IAC9B,OAAOA,sBAAsB,KAAK,SAAS,EAC3C;IACA,MAAM,IAAIE,KAAK,CACb,2DACF,CAAC;EACH;EAEA,OAAO;IACLC,IAAI,EAAE,0BAA0B;IAEhCC,iBAAiBA,CAAC;MAAEC,UAAU;MAAEC;IAAc,CAAC,EAAE;MAAA,IAAAC,qBAAA;MAC/C,CAAAA,qBAAA,GAAAD,aAAa,CAACE,uBAAuB,YAAAD,qBAAA,GAArCD,aAAa,CAACE,uBAAuB,GAAK,MAAM;MAChDH,UAAU,CAACI,OAAO,CAACC,IAAI,CAAC,CACtB,kBAAkB,EAClB;QAAEV,sBAAsB,EAAEW,OAAO,CAACX,sBAAsB;MAAE,CAAC,CAC5D,CAAC;IACJ;EACF,CAAC;AACH,CAAC,CAAC;AAAAY,OAAA,CAAAC,OAAA,GAAAhB,QAAA"}
\ No newline at end of file |
