feat: refactoring project
This commit is contained in:
18
node_modules/@babel/plugin-syntax-import-assertions/lib/index.js
generated
vendored
18
node_modules/@babel/plugin-syntax-import-assertions/lib/index.js
generated
vendored
@@ -7,10 +7,24 @@ exports.default = void 0;
|
||||
var _helperPluginUtils = require("@babel/helper-plugin-utils");
|
||||
var _default = exports.default = (0, _helperPluginUtils.declare)(api => {
|
||||
api.assertVersion(7);
|
||||
const isPlugin = (plugin, name) => name === "plugin" || Array.isArray(plugin) && plugin[0] === "plugin";
|
||||
const options = plugin => Array.isArray(plugin) && plugin.length > 1 ? plugin[1] : {};
|
||||
return {
|
||||
name: "syntax-import-assertions",
|
||||
manipulateOptions(opts, parserOpts) {
|
||||
parserOpts.plugins.push("importAssertions");
|
||||
manipulateOptions(opts, {
|
||||
plugins
|
||||
}) {
|
||||
for (let i = 0; i < plugins.length; i++) {
|
||||
const plugin = plugins[i];
|
||||
if (isPlugin(plugin, "deprecatedImportAssert")) return;
|
||||
if (isPlugin(plugin, "importAttributes")) {
|
||||
plugins.splice(i, 1, "deprecatedImportAssert", ["importAttributes", Object.assign({}, options(plugin), {
|
||||
deprecatedAssertSyntax: true
|
||||
})]);
|
||||
return;
|
||||
}
|
||||
}
|
||||
plugins.push("importAssertions");
|
||||
}
|
||||
};
|
||||
});
|
||||
|
||||
2
node_modules/@babel/plugin-syntax-import-assertions/lib/index.js.map
generated
vendored
2
node_modules/@babel/plugin-syntax-import-assertions/lib/index.js.map
generated
vendored
@@ -1 +1 @@
|
||||
{"version":3,"names":["_helperPluginUtils","require","_default","exports","default","declare","api","assertVersion","name","manipulateOptions","opts","parserOpts","plugins","push"],"sources":["../src/index.ts"],"sourcesContent":["import { declare } from \"@babel/helper-plugin-utils\";\n\nexport default declare(api => {\n api.assertVersion(REQUIRED_VERSION(7));\n\n return {\n name: \"syntax-import-assertions\",\n\n manipulateOptions(opts, parserOpts) {\n parserOpts.plugins.push(\"importAssertions\");\n },\n };\n});\n"],"mappings":";;;;;;AAAA,IAAAA,kBAAA,GAAAC,OAAA;AAAqD,IAAAC,QAAA,GAAAC,OAAA,CAAAC,OAAA,GAEtC,IAAAC,0BAAO,EAACC,GAAG,IAAI;EAC5BA,GAAG,CAACC,aAAa,CAAkB,CAAE,CAAC;EAEtC,OAAO;IACLC,IAAI,EAAE,0BAA0B;IAEhCC,iBAAiBA,CAACC,IAAI,EAAEC,UAAU,EAAE;MAClCA,UAAU,CAACC,OAAO,CAACC,IAAI,CAAC,kBAAkB,CAAC;IAC7C;EACF,CAAC;AACH,CAAC,CAAC","ignoreList":[]}
|
||||
{"version":3,"names":["_helperPluginUtils","require","_default","exports","default","declare","api","assertVersion","isPlugin","plugin","name","Array","isArray","options","length","manipulateOptions","opts","plugins","i","splice","Object","assign","deprecatedAssertSyntax","push"],"sources":["../src/index.ts"],"sourcesContent":["import { declare } from \"@babel/helper-plugin-utils\";\n\nexport default declare(api => {\n api.assertVersion(REQUIRED_VERSION(7));\n\n const isPlugin = (plugin: string | [string, object], name: string) =>\n name === \"plugin\" || (Array.isArray(plugin) && plugin[0] === \"plugin\");\n const options = (plugin: string | [string, object]) =>\n Array.isArray(plugin) && plugin.length > 1 ? plugin[1] : {};\n\n return {\n name: \"syntax-import-assertions\",\n\n manipulateOptions(opts, { plugins }) {\n for (let i = 0; i < plugins.length; i++) {\n const plugin = plugins[i];\n\n if (isPlugin(plugin, \"deprecatedImportAssert\")) return;\n\n if (isPlugin(plugin, \"importAttributes\")) {\n plugins.splice(i, 1, \"deprecatedImportAssert\", [\n \"importAttributes\",\n { ...options(plugin), deprecatedAssertSyntax: true },\n ]);\n return;\n }\n }\n\n plugins.push(\"importAssertions\");\n },\n };\n});\n"],"mappings":";;;;;;AAAA,IAAAA,kBAAA,GAAAC,OAAA;AAAqD,IAAAC,QAAA,GAAAC,OAAA,CAAAC,OAAA,GAEtC,IAAAC,0BAAO,EAACC,GAAG,IAAI;EAC5BA,GAAG,CAACC,aAAa,CAAkB,CAAE,CAAC;EAEtC,MAAMC,QAAQ,GAAGA,CAACC,MAAiC,EAAEC,IAAY,KAC/DA,IAAI,KAAK,QAAQ,IAAKC,KAAK,CAACC,OAAO,CAACH,MAAM,CAAC,IAAIA,MAAM,CAAC,CAAC,CAAC,KAAK,QAAS;EACxE,MAAMI,OAAO,GAAIJ,MAAiC,IAChDE,KAAK,CAACC,OAAO,CAACH,MAAM,CAAC,IAAIA,MAAM,CAACK,MAAM,GAAG,CAAC,GAAGL,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;EAE7D,OAAO;IACLC,IAAI,EAAE,0BAA0B;IAEhCK,iBAAiBA,CAACC,IAAI,EAAE;MAAEC;IAAQ,CAAC,EAAE;MACnC,KAAK,IAAIC,CAAC,GAAG,CAAC,EAAEA,CAAC,GAAGD,OAAO,CAACH,MAAM,EAAEI,CAAC,EAAE,EAAE;QACvC,MAAMT,MAAM,GAAGQ,OAAO,CAACC,CAAC,CAAC;QAEzB,IAAIV,QAAQ,CAACC,MAAM,EAAE,wBAAwB,CAAC,EAAE;QAEhD,IAAID,QAAQ,CAACC,MAAM,EAAE,kBAAkB,CAAC,EAAE;UACxCQ,OAAO,CAACE,MAAM,CAACD,CAAC,EAAE,CAAC,EAAE,wBAAwB,EAAE,CAC7C,kBAAkB,EAAAE,MAAA,CAAAC,MAAA,KACbR,OAAO,CAACJ,MAAM,CAAC;YAAEa,sBAAsB,EAAE;UAAI,GACnD,CAAC;UACF;QACF;MACF;MAEAL,OAAO,CAACM,IAAI,CAAC,kBAAkB,CAAC;IAClC;EACF,CAAC;AACH,CAAC,CAAC","ignoreList":[]}
|
||||
6
node_modules/@babel/plugin-syntax-import-assertions/package.json
generated
vendored
6
node_modules/@babel/plugin-syntax-import-assertions/package.json
generated
vendored
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@babel/plugin-syntax-import-assertions",
|
||||
"version": "7.24.7",
|
||||
"version": "7.26.0",
|
||||
"description": "Allow parsing of the module assertion attributes in the import statement",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
@@ -16,13 +16,13 @@
|
||||
"babel-plugin"
|
||||
],
|
||||
"dependencies": {
|
||||
"@babel/helper-plugin-utils": "^7.24.7"
|
||||
"@babel/helper-plugin-utils": "^7.25.9"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"@babel/core": "^7.0.0-0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.24.7"
|
||||
"@babel/core": "^7.26.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=6.9.0"
|
||||
|
||||
17
node_modules/@babel/plugin-syntax-import-assertions/tsconfig.json
generated
vendored
17
node_modules/@babel/plugin-syntax-import-assertions/tsconfig.json
generated
vendored
@@ -1,17 +0,0 @@
|
||||
/* This file is automatically generated by scripts/generators/tsconfig.js */
|
||||
{
|
||||
"extends": [
|
||||
"../../tsconfig.base.json",
|
||||
"../../tsconfig.paths.json"
|
||||
],
|
||||
"include": [
|
||||
"../../packages/babel-plugin-syntax-import-assertions/src/**/*.ts",
|
||||
"../../lib/globals.d.ts",
|
||||
"../../scripts/repo-utils/*.d.ts"
|
||||
],
|
||||
"references": [
|
||||
{
|
||||
"path": "../../packages/babel-helper-plugin-utils"
|
||||
}
|
||||
]
|
||||
}
|
||||
1
node_modules/@babel/plugin-syntax-import-assertions/tsconfig.tsbuildinfo
generated
vendored
1
node_modules/@babel/plugin-syntax-import-assertions/tsconfig.tsbuildinfo
generated
vendored
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user