@vue.ts/tsx-auto-props 0.6.0 → 1.0.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -21
- package/README.md +19 -0
- package/dist/astro.d.ts +8 -8
- package/dist/astro.js +14 -0
- package/dist/esbuild.d.ts +6 -6
- package/dist/esbuild.js +8 -0
- package/dist/farm.d.ts +7 -0
- package/dist/farm.js +8 -0
- package/dist/index.d.ts +8 -6
- package/dist/index.js +3 -0
- package/dist/nuxt.d.ts +6 -6
- package/dist/nuxt.js +20 -0
- package/dist/rolldown.d.ts +7 -0
- package/dist/rolldown.js +8 -0
- package/dist/rollup.d.ts +6 -6
- package/dist/rollup.js +8 -0
- package/dist/rspack.d.ts +4 -4
- package/dist/rspack.js +8 -0
- package/dist/src-CWmlC_RH.js +96 -0
- package/dist/types-BsMRL-YJ.d.ts +15 -0
- package/dist/types.d.ts +2 -8
- package/dist/types.js +0 -0
- package/dist/vite-CO8uPslf.js +8 -0
- package/dist/vite.d.ts +6 -6
- package/dist/vite.js +4 -0
- package/dist/webpack-Bs4ZyN2r.js +8 -0
- package/dist/webpack.d.ts +6 -6
- package/dist/webpack.js +4 -0
- package/package.json +65 -54
- package/dist/astro.cjs +0 -22
- package/dist/astro.d.cts +0 -11
- package/dist/astro.d.mts +0 -11
- package/dist/astro.mjs +0 -20
- package/dist/esbuild.cjs +0 -13
- package/dist/esbuild.d.cts +0 -7
- package/dist/esbuild.d.mts +0 -7
- package/dist/esbuild.mjs +0 -11
- package/dist/index.cjs +0 -119
- package/dist/index.d.cts +0 -7
- package/dist/index.d.mts +0 -7
- package/dist/index.mjs +0 -112
- package/dist/nuxt.cjs +0 -35
- package/dist/nuxt.d.cts +0 -7
- package/dist/nuxt.d.mts +0 -7
- package/dist/nuxt.mjs +0 -33
- package/dist/rollup.cjs +0 -13
- package/dist/rollup.d.cts +0 -7
- package/dist/rollup.d.mts +0 -7
- package/dist/rollup.mjs +0 -11
- package/dist/rspack.cjs +0 -13
- package/dist/rspack.d.cts +0 -6
- package/dist/rspack.d.mts +0 -6
- package/dist/rspack.mjs +0 -11
- package/dist/types.cjs +0 -2
- package/dist/types.d.cts +0 -8
- package/dist/types.d.mts +0 -8
- package/dist/types.mjs +0 -1
- package/dist/vite.cjs +0 -13
- package/dist/vite.d.cts +0 -7
- package/dist/vite.d.mts +0 -7
- package/dist/vite.mjs +0 -11
- package/dist/webpack.cjs +0 -13
- package/dist/webpack.d.cts +0 -7
- package/dist/webpack.d.mts +0 -7
- package/dist/webpack.mjs +0 -11
package/dist/astro.d.mts
DELETED
package/dist/astro.mjs
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import unplugin from './index.mjs';
|
|
2
|
-
import '@vue.ts/common';
|
|
3
|
-
import '@vue.ts/language';
|
|
4
|
-
import 'unplugin';
|
|
5
|
-
import 'magic-string';
|
|
6
|
-
import 'typescript';
|
|
7
|
-
import 'node:path';
|
|
8
|
-
|
|
9
|
-
const astro = (options) => ({
|
|
10
|
-
name: "@vue.ts/complex-types",
|
|
11
|
-
hooks: {
|
|
12
|
-
"astro:config:setup": async (astro) => {
|
|
13
|
-
var _a;
|
|
14
|
-
(_a = astro.config.vite).plugins || (_a.plugins = []);
|
|
15
|
-
astro.config.vite.plugins.push(unplugin.vite(options));
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
export { astro as default };
|
package/dist/esbuild.cjs
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
const index = require('./index.cjs');
|
|
4
|
-
require('@vue.ts/common');
|
|
5
|
-
require('@vue.ts/language');
|
|
6
|
-
require('unplugin');
|
|
7
|
-
require('magic-string');
|
|
8
|
-
require('typescript');
|
|
9
|
-
require('node:path');
|
|
10
|
-
|
|
11
|
-
const esbuild = index.esbuild;
|
|
12
|
-
|
|
13
|
-
module.exports = esbuild;
|
package/dist/esbuild.d.cts
DELETED
package/dist/esbuild.d.mts
DELETED
package/dist/esbuild.mjs
DELETED
package/dist/index.cjs
DELETED
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
const common = require('@vue.ts/common');
|
|
4
|
-
const language = require('@vue.ts/language');
|
|
5
|
-
const unplugin$1 = require('unplugin');
|
|
6
|
-
const MagicString = require('magic-string');
|
|
7
|
-
const ts = require('typescript');
|
|
8
|
-
const node_path = require('node:path');
|
|
9
|
-
|
|
10
|
-
function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'default' in e ? e.default : e; }
|
|
11
|
-
|
|
12
|
-
const MagicString__default = /*#__PURE__*/_interopDefaultCompat(MagicString);
|
|
13
|
-
const ts__default = /*#__PURE__*/_interopDefaultCompat(ts);
|
|
14
|
-
|
|
15
|
-
const resolveOptions = (rawOptions) => ({
|
|
16
|
-
include: rawOptions.include ?? ["**/*.vue", "**/*.tsx"],
|
|
17
|
-
exclude: rawOptions.exclude ?? ["node_modules/**"],
|
|
18
|
-
tsconfigPath: rawOptions.tsconfigPath ?? node_path.join(process.cwd(), "tsconfig.json")
|
|
19
|
-
});
|
|
20
|
-
function getNodeAssignNode(node) {
|
|
21
|
-
let parent = null;
|
|
22
|
-
let variableList = null;
|
|
23
|
-
let variable = null;
|
|
24
|
-
while (node) {
|
|
25
|
-
if (parent) {
|
|
26
|
-
if (ts__default.isVariableDeclarationList(parent)) {
|
|
27
|
-
variableList = parent;
|
|
28
|
-
}
|
|
29
|
-
if (ts__default.isVariableDeclaration(parent)) {
|
|
30
|
-
variable = parent;
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
parent = node;
|
|
34
|
-
node = node.parent;
|
|
35
|
-
}
|
|
36
|
-
return { variableList, variable };
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
const generateDefineProps = (name, props) => `
|
|
40
|
-
;Object.defineProperty(${name}, "props", {
|
|
41
|
-
value: ${JSON.stringify(props)},
|
|
42
|
-
});`;
|
|
43
|
-
const DEFINE_COMPONENT = "defineComponent";
|
|
44
|
-
function transform(code, id) {
|
|
45
|
-
const s = new MagicString__default(code);
|
|
46
|
-
const language$1 = language.getLanguage();
|
|
47
|
-
const typeChecker = language$1.__internal__.typeChecker;
|
|
48
|
-
language$1.traverseAst(
|
|
49
|
-
id,
|
|
50
|
-
(node, { virtualFileOrTsAst: ast, isVirtualOrTsFile }) => {
|
|
51
|
-
if (isVirtualOrTsFile && ts__default.isCallExpression(node)) {
|
|
52
|
-
const identifier = node.expression;
|
|
53
|
-
const symbol = typeChecker.getSymbolAtLocation(identifier);
|
|
54
|
-
if (symbol?.declarations?.some(
|
|
55
|
-
(d) => ts__default.isImportSpecifier(d) && (d.propertyName ?? d.name)?.escapedText === DEFINE_COMPONENT
|
|
56
|
-
)) {
|
|
57
|
-
const arg = node.arguments[0];
|
|
58
|
-
let setupFn;
|
|
59
|
-
if (ts__default.isObjectLiteralExpression(arg)) {
|
|
60
|
-
const props2 = arg.properties.find(
|
|
61
|
-
(p) => ts__default.isPropertyAssignment(p) && ts__default.isIdentifier(p.name) && p.name.escapedText === "props"
|
|
62
|
-
);
|
|
63
|
-
const setup = arg.properties.find(
|
|
64
|
-
(p) => ts__default.isPropertyAssignment(p) && ts__default.isIdentifier(p.name) && p.name.escapedText === "setup"
|
|
65
|
-
);
|
|
66
|
-
if (!props2 && setup && ts__default.isPropertyAssignment(setup)) {
|
|
67
|
-
const value = setup.initializer;
|
|
68
|
-
if (ts__default.isFunctionLike(value)) {
|
|
69
|
-
setupFn = value;
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
} else if (ts__default.isFunctionLike(arg)) {
|
|
73
|
-
setupFn = arg;
|
|
74
|
-
} else {
|
|
75
|
-
throw new Error(
|
|
76
|
-
"[@vue.ts/tsx-auto-props] Invalid defineComponent argument"
|
|
77
|
-
);
|
|
78
|
-
}
|
|
79
|
-
const props = setupFn?.parameters[0];
|
|
80
|
-
if (props) {
|
|
81
|
-
const propsList = typeChecker.getTypeAtLocation(props).getProperties().map((p) => p.name);
|
|
82
|
-
const { variableList, variable } = getNodeAssignNode(node);
|
|
83
|
-
if (propsList.length > 0 && variableList && variable) {
|
|
84
|
-
s.appendRight(
|
|
85
|
-
variableList.getEnd() + 1,
|
|
86
|
-
generateDefineProps(variable.name.getText(ast), propsList)
|
|
87
|
-
);
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
);
|
|
94
|
-
return {
|
|
95
|
-
code: s.toString(),
|
|
96
|
-
map: s.generateMap({ hires: true })
|
|
97
|
-
};
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
const unplugin = unplugin$1.createUnplugin((options = {}) => ({
|
|
101
|
-
name: "@vue.ts/complex-types",
|
|
102
|
-
buildStart() {
|
|
103
|
-
const resolvedOptions = resolveOptions(options);
|
|
104
|
-
language.ensureLanguage(resolvedOptions.tsconfigPath);
|
|
105
|
-
},
|
|
106
|
-
transform(code, id) {
|
|
107
|
-
const resolvedOptions = resolveOptions(options);
|
|
108
|
-
const filter = common.createFilter(
|
|
109
|
-
resolvedOptions.include,
|
|
110
|
-
resolvedOptions.exclude
|
|
111
|
-
);
|
|
112
|
-
if (!filter(id)) {
|
|
113
|
-
return;
|
|
114
|
-
}
|
|
115
|
-
return transform(code, id);
|
|
116
|
-
}
|
|
117
|
-
}));
|
|
118
|
-
|
|
119
|
-
module.exports = unplugin;
|
package/dist/index.d.cts
DELETED
package/dist/index.d.mts
DELETED
package/dist/index.mjs
DELETED
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
import { createFilter } from '@vue.ts/common';
|
|
2
|
-
import { getLanguage, ensureLanguage } from '@vue.ts/language';
|
|
3
|
-
import { createUnplugin } from 'unplugin';
|
|
4
|
-
import MagicString from 'magic-string';
|
|
5
|
-
import ts from 'typescript';
|
|
6
|
-
import { join } from 'node:path';
|
|
7
|
-
|
|
8
|
-
const resolveOptions = (rawOptions) => ({
|
|
9
|
-
include: rawOptions.include ?? ["**/*.vue", "**/*.tsx"],
|
|
10
|
-
exclude: rawOptions.exclude ?? ["node_modules/**"],
|
|
11
|
-
tsconfigPath: rawOptions.tsconfigPath ?? join(process.cwd(), "tsconfig.json")
|
|
12
|
-
});
|
|
13
|
-
function getNodeAssignNode(node) {
|
|
14
|
-
let parent = null;
|
|
15
|
-
let variableList = null;
|
|
16
|
-
let variable = null;
|
|
17
|
-
while (node) {
|
|
18
|
-
if (parent) {
|
|
19
|
-
if (ts.isVariableDeclarationList(parent)) {
|
|
20
|
-
variableList = parent;
|
|
21
|
-
}
|
|
22
|
-
if (ts.isVariableDeclaration(parent)) {
|
|
23
|
-
variable = parent;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
parent = node;
|
|
27
|
-
node = node.parent;
|
|
28
|
-
}
|
|
29
|
-
return { variableList, variable };
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
const generateDefineProps = (name, props) => `
|
|
33
|
-
;Object.defineProperty(${name}, "props", {
|
|
34
|
-
value: ${JSON.stringify(props)},
|
|
35
|
-
});`;
|
|
36
|
-
const DEFINE_COMPONENT = "defineComponent";
|
|
37
|
-
function transform(code, id) {
|
|
38
|
-
const s = new MagicString(code);
|
|
39
|
-
const language = getLanguage();
|
|
40
|
-
const typeChecker = language.__internal__.typeChecker;
|
|
41
|
-
language.traverseAst(
|
|
42
|
-
id,
|
|
43
|
-
(node, { virtualFileOrTsAst: ast, isVirtualOrTsFile }) => {
|
|
44
|
-
if (isVirtualOrTsFile && ts.isCallExpression(node)) {
|
|
45
|
-
const identifier = node.expression;
|
|
46
|
-
const symbol = typeChecker.getSymbolAtLocation(identifier);
|
|
47
|
-
if (symbol?.declarations?.some(
|
|
48
|
-
(d) => ts.isImportSpecifier(d) && (d.propertyName ?? d.name)?.escapedText === DEFINE_COMPONENT
|
|
49
|
-
)) {
|
|
50
|
-
const arg = node.arguments[0];
|
|
51
|
-
let setupFn;
|
|
52
|
-
if (ts.isObjectLiteralExpression(arg)) {
|
|
53
|
-
const props2 = arg.properties.find(
|
|
54
|
-
(p) => ts.isPropertyAssignment(p) && ts.isIdentifier(p.name) && p.name.escapedText === "props"
|
|
55
|
-
);
|
|
56
|
-
const setup = arg.properties.find(
|
|
57
|
-
(p) => ts.isPropertyAssignment(p) && ts.isIdentifier(p.name) && p.name.escapedText === "setup"
|
|
58
|
-
);
|
|
59
|
-
if (!props2 && setup && ts.isPropertyAssignment(setup)) {
|
|
60
|
-
const value = setup.initializer;
|
|
61
|
-
if (ts.isFunctionLike(value)) {
|
|
62
|
-
setupFn = value;
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
} else if (ts.isFunctionLike(arg)) {
|
|
66
|
-
setupFn = arg;
|
|
67
|
-
} else {
|
|
68
|
-
throw new Error(
|
|
69
|
-
"[@vue.ts/tsx-auto-props] Invalid defineComponent argument"
|
|
70
|
-
);
|
|
71
|
-
}
|
|
72
|
-
const props = setupFn?.parameters[0];
|
|
73
|
-
if (props) {
|
|
74
|
-
const propsList = typeChecker.getTypeAtLocation(props).getProperties().map((p) => p.name);
|
|
75
|
-
const { variableList, variable } = getNodeAssignNode(node);
|
|
76
|
-
if (propsList.length > 0 && variableList && variable) {
|
|
77
|
-
s.appendRight(
|
|
78
|
-
variableList.getEnd() + 1,
|
|
79
|
-
generateDefineProps(variable.name.getText(ast), propsList)
|
|
80
|
-
);
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
);
|
|
87
|
-
return {
|
|
88
|
-
code: s.toString(),
|
|
89
|
-
map: s.generateMap({ hires: true })
|
|
90
|
-
};
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
const unplugin = createUnplugin((options = {}) => ({
|
|
94
|
-
name: "@vue.ts/complex-types",
|
|
95
|
-
buildStart() {
|
|
96
|
-
const resolvedOptions = resolveOptions(options);
|
|
97
|
-
ensureLanguage(resolvedOptions.tsconfigPath);
|
|
98
|
-
},
|
|
99
|
-
transform(code, id) {
|
|
100
|
-
const resolvedOptions = resolveOptions(options);
|
|
101
|
-
const filter = createFilter(
|
|
102
|
-
resolvedOptions.include,
|
|
103
|
-
resolvedOptions.exclude
|
|
104
|
-
);
|
|
105
|
-
if (!filter(id)) {
|
|
106
|
-
return;
|
|
107
|
-
}
|
|
108
|
-
return transform(code, id);
|
|
109
|
-
}
|
|
110
|
-
}));
|
|
111
|
-
|
|
112
|
-
export { unplugin as default };
|
package/dist/nuxt.cjs
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
const kit = require('@nuxt/kit');
|
|
4
|
-
const vite = require('./vite.cjs');
|
|
5
|
-
const webpack = require('./webpack.cjs');
|
|
6
|
-
require('./index.cjs');
|
|
7
|
-
require('@vue.ts/common');
|
|
8
|
-
require('@vue.ts/language');
|
|
9
|
-
require('unplugin');
|
|
10
|
-
require('magic-string');
|
|
11
|
-
require('typescript');
|
|
12
|
-
require('node:path');
|
|
13
|
-
|
|
14
|
-
const name = "@vue.ts/tsx-auto-props";
|
|
15
|
-
const version = "0.6.0";
|
|
16
|
-
|
|
17
|
-
const nuxt = kit.defineNuxtModule({
|
|
18
|
-
meta: {
|
|
19
|
-
name,
|
|
20
|
-
version,
|
|
21
|
-
configKey: "complexTypes",
|
|
22
|
-
compatibility: {
|
|
23
|
-
bridge: true
|
|
24
|
-
}
|
|
25
|
-
},
|
|
26
|
-
defaults: {
|
|
27
|
-
tsconfigPath: "tsconfig.json"
|
|
28
|
-
},
|
|
29
|
-
setup(options) {
|
|
30
|
-
kit.addVitePlugin(vite(options));
|
|
31
|
-
kit.addWebpackPlugin(webpack(options));
|
|
32
|
-
}
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
module.exports = nuxt;
|
package/dist/nuxt.d.cts
DELETED
package/dist/nuxt.d.mts
DELETED
package/dist/nuxt.mjs
DELETED
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { defineNuxtModule, addVitePlugin, addWebpackPlugin } from '@nuxt/kit';
|
|
2
|
-
import VitePlugin from './vite.mjs';
|
|
3
|
-
import WebpackPlugin from './webpack.mjs';
|
|
4
|
-
import './index.mjs';
|
|
5
|
-
import '@vue.ts/common';
|
|
6
|
-
import '@vue.ts/language';
|
|
7
|
-
import 'unplugin';
|
|
8
|
-
import 'magic-string';
|
|
9
|
-
import 'typescript';
|
|
10
|
-
import 'node:path';
|
|
11
|
-
|
|
12
|
-
const name = "@vue.ts/tsx-auto-props";
|
|
13
|
-
const version = "0.6.0";
|
|
14
|
-
|
|
15
|
-
const nuxt = defineNuxtModule({
|
|
16
|
-
meta: {
|
|
17
|
-
name,
|
|
18
|
-
version,
|
|
19
|
-
configKey: "complexTypes",
|
|
20
|
-
compatibility: {
|
|
21
|
-
bridge: true
|
|
22
|
-
}
|
|
23
|
-
},
|
|
24
|
-
defaults: {
|
|
25
|
-
tsconfigPath: "tsconfig.json"
|
|
26
|
-
},
|
|
27
|
-
setup(options) {
|
|
28
|
-
addVitePlugin(VitePlugin(options));
|
|
29
|
-
addWebpackPlugin(WebpackPlugin(options));
|
|
30
|
-
}
|
|
31
|
-
});
|
|
32
|
-
|
|
33
|
-
export { nuxt as default };
|
package/dist/rollup.cjs
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
const index = require('./index.cjs');
|
|
4
|
-
require('@vue.ts/common');
|
|
5
|
-
require('@vue.ts/language');
|
|
6
|
-
require('unplugin');
|
|
7
|
-
require('magic-string');
|
|
8
|
-
require('typescript');
|
|
9
|
-
require('node:path');
|
|
10
|
-
|
|
11
|
-
const rollup = index.rollup;
|
|
12
|
-
|
|
13
|
-
module.exports = rollup;
|
package/dist/rollup.d.cts
DELETED
package/dist/rollup.d.mts
DELETED
package/dist/rollup.mjs
DELETED
package/dist/rspack.cjs
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
const index = require('./index.cjs');
|
|
4
|
-
require('@vue.ts/common');
|
|
5
|
-
require('@vue.ts/language');
|
|
6
|
-
require('unplugin');
|
|
7
|
-
require('magic-string');
|
|
8
|
-
require('typescript');
|
|
9
|
-
require('node:path');
|
|
10
|
-
|
|
11
|
-
const rspack = index.rspack;
|
|
12
|
-
|
|
13
|
-
module.exports = rspack;
|
package/dist/rspack.d.cts
DELETED
package/dist/rspack.d.mts
DELETED
package/dist/rspack.mjs
DELETED
package/dist/types.cjs
DELETED
package/dist/types.d.cts
DELETED
package/dist/types.d.mts
DELETED
package/dist/types.mjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|
package/dist/vite.cjs
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
const index = require('./index.cjs');
|
|
4
|
-
require('@vue.ts/common');
|
|
5
|
-
require('@vue.ts/language');
|
|
6
|
-
require('unplugin');
|
|
7
|
-
require('magic-string');
|
|
8
|
-
require('typescript');
|
|
9
|
-
require('node:path');
|
|
10
|
-
|
|
11
|
-
const VitePlugin = index.vite;
|
|
12
|
-
|
|
13
|
-
module.exports = VitePlugin;
|
package/dist/vite.d.cts
DELETED
package/dist/vite.d.mts
DELETED
package/dist/vite.mjs
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import unplugin from './index.mjs';
|
|
2
|
-
import '@vue.ts/common';
|
|
3
|
-
import '@vue.ts/language';
|
|
4
|
-
import 'unplugin';
|
|
5
|
-
import 'magic-string';
|
|
6
|
-
import 'typescript';
|
|
7
|
-
import 'node:path';
|
|
8
|
-
|
|
9
|
-
const VitePlugin = unplugin.vite;
|
|
10
|
-
|
|
11
|
-
export { VitePlugin as default };
|
package/dist/webpack.cjs
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
const index = require('./index.cjs');
|
|
4
|
-
require('@vue.ts/common');
|
|
5
|
-
require('@vue.ts/language');
|
|
6
|
-
require('unplugin');
|
|
7
|
-
require('magic-string');
|
|
8
|
-
require('typescript');
|
|
9
|
-
require('node:path');
|
|
10
|
-
|
|
11
|
-
const WebpackPlugin = index.webpack;
|
|
12
|
-
|
|
13
|
-
module.exports = WebpackPlugin;
|
package/dist/webpack.d.cts
DELETED
package/dist/webpack.d.mts
DELETED
package/dist/webpack.mjs
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import unplugin from './index.mjs';
|
|
2
|
-
import '@vue.ts/common';
|
|
3
|
-
import '@vue.ts/language';
|
|
4
|
-
import 'unplugin';
|
|
5
|
-
import 'magic-string';
|
|
6
|
-
import 'typescript';
|
|
7
|
-
import 'node:path';
|
|
8
|
-
|
|
9
|
-
const WebpackPlugin = unplugin.webpack;
|
|
10
|
-
|
|
11
|
-
export { WebpackPlugin as default };
|