unplugin-vue-components 0.20.0 → 0.20.1
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/dist/{chunk-7NLFLZZX.mjs → chunk-3HI6HDVM.mjs} +13 -8
- package/dist/{chunk-46PS2JCI.js → chunk-PIMN6CZ7.js} +13 -8
- package/dist/esbuild.js +2 -2
- package/dist/esbuild.mjs +1 -1
- package/dist/index.js +2 -2
- package/dist/index.mjs +1 -1
- package/dist/nuxt.js +3 -3
- package/dist/nuxt.mjs +1 -1
- package/dist/rollup.js +2 -2
- package/dist/rollup.mjs +1 -1
- package/dist/vite.js +2 -2
- package/dist/vite.mjs +1 -1
- package/dist/webpack.js +2 -2
- package/dist/webpack.mjs +1 -1
- package/package.json +15 -14
|
@@ -561,6 +561,7 @@ var Context = class {
|
|
|
561
561
|
};
|
|
562
562
|
|
|
563
563
|
// src/core/unplugin.ts
|
|
564
|
+
var PLUGIN_NAME = "unplugin:webpack";
|
|
564
565
|
var unplugin_default = createUnplugin((options = {}) => {
|
|
565
566
|
const filter = createFilter(options.include || [/\.vue$/, /\.vue\?vue/], options.exclude || [/[\\/]node_modules[\\/]/, /[\\/]\.git[\\/]/, /[\\/]\.nuxt[\\/]/]);
|
|
566
567
|
const ctx = new Context(options);
|
|
@@ -608,16 +609,20 @@ var unplugin_default = createUnplugin((options = {}) => {
|
|
|
608
609
|
}
|
|
609
610
|
},
|
|
610
611
|
webpack(compiler) {
|
|
611
|
-
|
|
612
|
-
return;
|
|
612
|
+
let watcher;
|
|
613
613
|
let fileDepQueue = [];
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
614
|
+
compiler.hooks.watchRun.tap(PLUGIN_NAME, () => {
|
|
615
|
+
if (!watcher && compiler.watching) {
|
|
616
|
+
watcher = compiler.watching;
|
|
617
|
+
ctx.setupWatcherWebpack(chokidar.watch(ctx.options.globs), (path, type) => {
|
|
618
|
+
fileDepQueue.push({ path, type });
|
|
619
|
+
process.nextTick(() => {
|
|
620
|
+
watcher.invalidate();
|
|
621
|
+
});
|
|
622
|
+
});
|
|
623
|
+
}
|
|
619
624
|
});
|
|
620
|
-
compiler.hooks.compilation.tap(
|
|
625
|
+
compiler.hooks.compilation.tap(PLUGIN_NAME, (compilation) => {
|
|
621
626
|
if (fileDepQueue.length) {
|
|
622
627
|
fileDepQueue.forEach(({ path, type }) => {
|
|
623
628
|
if (type === "unlink")
|
|
@@ -561,6 +561,7 @@ var Context = class {
|
|
|
561
561
|
};
|
|
562
562
|
|
|
563
563
|
// src/core/unplugin.ts
|
|
564
|
+
var PLUGIN_NAME = "unplugin:webpack";
|
|
564
565
|
var unplugin_default = _unplugin.createUnplugin.call(void 0, (options = {}) => {
|
|
565
566
|
const filter = _pluginutils.createFilter.call(void 0, options.include || [/\.vue$/, /\.vue\?vue/], options.exclude || [/[\\/]node_modules[\\/]/, /[\\/]\.git[\\/]/, /[\\/]\.nuxt[\\/]/]);
|
|
566
567
|
const ctx = new Context(options);
|
|
@@ -608,16 +609,20 @@ var unplugin_default = _unplugin.createUnplugin.call(void 0, (options = {}) => {
|
|
|
608
609
|
}
|
|
609
610
|
},
|
|
610
611
|
webpack(compiler) {
|
|
611
|
-
|
|
612
|
-
return;
|
|
612
|
+
let watcher;
|
|
613
613
|
let fileDepQueue = [];
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
614
|
+
compiler.hooks.watchRun.tap(PLUGIN_NAME, () => {
|
|
615
|
+
if (!watcher && compiler.watching) {
|
|
616
|
+
watcher = compiler.watching;
|
|
617
|
+
ctx.setupWatcherWebpack(_chokidar2.default.watch(ctx.options.globs), (path, type) => {
|
|
618
|
+
fileDepQueue.push({ path, type });
|
|
619
|
+
process.nextTick(() => {
|
|
620
|
+
watcher.invalidate();
|
|
621
|
+
});
|
|
622
|
+
});
|
|
623
|
+
}
|
|
619
624
|
});
|
|
620
|
-
compiler.hooks.compilation.tap(
|
|
625
|
+
compiler.hooks.compilation.tap(PLUGIN_NAME, (compilation) => {
|
|
621
626
|
if (fileDepQueue.length) {
|
|
622
627
|
fileDepQueue.forEach(({ path, type }) => {
|
|
623
628
|
if (type === "unlink")
|
package/dist/esbuild.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkPIMN6CZ7js = require('./chunk-PIMN6CZ7.js');
|
|
4
4
|
require('./chunk-FD6BQCQ7.js');
|
|
5
5
|
require('./chunk-BTQOTIPQ.js');
|
|
6
6
|
require('./chunk-6F4PWJZI.js');
|
|
7
7
|
|
|
8
8
|
// src/esbuild.ts
|
|
9
|
-
var esbuild_default =
|
|
9
|
+
var esbuild_default = _chunkPIMN6CZ7js.unplugin_default.esbuild;
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
module.exports = esbuild_default;
|
package/dist/esbuild.mjs
CHANGED
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkPIMN6CZ7js = require('./chunk-PIMN6CZ7.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
@@ -13,4 +13,4 @@ require('./chunk-6F4PWJZI.js');
|
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
exports.camelCase = _chunkFD6BQCQ7js.camelCase; exports.default =
|
|
16
|
+
exports.camelCase = _chunkFD6BQCQ7js.camelCase; exports.default = _chunkPIMN6CZ7js.unplugin_default; exports.kebabCase = _chunkFD6BQCQ7js.kebabCase; exports.pascalCase = _chunkFD6BQCQ7js.pascalCase;
|
package/dist/index.mjs
CHANGED
package/dist/nuxt.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkPIMN6CZ7js = require('./chunk-PIMN6CZ7.js');
|
|
4
4
|
require('./chunk-FD6BQCQ7.js');
|
|
5
5
|
require('./chunk-BTQOTIPQ.js');
|
|
6
6
|
require('./chunk-6F4PWJZI.js');
|
|
@@ -9,11 +9,11 @@ require('./chunk-6F4PWJZI.js');
|
|
|
9
9
|
function nuxt_default(options) {
|
|
10
10
|
this.extendBuild((config) => {
|
|
11
11
|
config.plugins = config.plugins || [];
|
|
12
|
-
config.plugins.unshift(
|
|
12
|
+
config.plugins.unshift(_chunkPIMN6CZ7js.unplugin_default.webpack(options));
|
|
13
13
|
});
|
|
14
14
|
this.nuxt.hook("vite:extend", async (vite) => {
|
|
15
15
|
vite.config.plugins = vite.config.plugins || [];
|
|
16
|
-
vite.config.plugins.push(
|
|
16
|
+
vite.config.plugins.push(_chunkPIMN6CZ7js.unplugin_default.vite(options));
|
|
17
17
|
});
|
|
18
18
|
}
|
|
19
19
|
|
package/dist/nuxt.mjs
CHANGED
package/dist/rollup.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkPIMN6CZ7js = require('./chunk-PIMN6CZ7.js');
|
|
4
4
|
require('./chunk-FD6BQCQ7.js');
|
|
5
5
|
require('./chunk-BTQOTIPQ.js');
|
|
6
6
|
require('./chunk-6F4PWJZI.js');
|
|
7
7
|
|
|
8
8
|
// src/rollup.ts
|
|
9
|
-
var rollup_default =
|
|
9
|
+
var rollup_default = _chunkPIMN6CZ7js.unplugin_default.rollup;
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
module.exports = rollup_default;
|
package/dist/rollup.mjs
CHANGED
package/dist/vite.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkPIMN6CZ7js = require('./chunk-PIMN6CZ7.js');
|
|
4
4
|
require('./chunk-FD6BQCQ7.js');
|
|
5
5
|
require('./chunk-BTQOTIPQ.js');
|
|
6
6
|
require('./chunk-6F4PWJZI.js');
|
|
7
7
|
|
|
8
8
|
// src/vite.ts
|
|
9
|
-
var vite_default =
|
|
9
|
+
var vite_default = _chunkPIMN6CZ7js.unplugin_default.vite;
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
module.exports = vite_default;
|
package/dist/vite.mjs
CHANGED
package/dist/webpack.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkPIMN6CZ7js = require('./chunk-PIMN6CZ7.js');
|
|
4
4
|
require('./chunk-FD6BQCQ7.js');
|
|
5
5
|
require('./chunk-BTQOTIPQ.js');
|
|
6
6
|
require('./chunk-6F4PWJZI.js');
|
|
7
7
|
|
|
8
8
|
// src/webpack.ts
|
|
9
|
-
var webpack_default =
|
|
9
|
+
var webpack_default = _chunkPIMN6CZ7js.unplugin_default.webpack;
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
module.exports = webpack_default;
|
package/dist/webpack.mjs
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "unplugin-vue-components",
|
|
3
|
-
"version": "0.20.
|
|
3
|
+
"version": "0.20.1",
|
|
4
4
|
"packageManager": "pnpm@7.1.5",
|
|
5
5
|
"description": "Components auto importing for Vue",
|
|
6
6
|
"author": "antfu <anthonyfu117@hotmail.com>",
|
|
@@ -63,6 +63,17 @@
|
|
|
63
63
|
"engines": {
|
|
64
64
|
"node": ">=14"
|
|
65
65
|
},
|
|
66
|
+
"scripts": {
|
|
67
|
+
"build": "tsup && esno scripts/postbuild.ts",
|
|
68
|
+
"dev": "tsup --watch src",
|
|
69
|
+
"example:build": "npm -C examples/vite-vue3 run build",
|
|
70
|
+
"example:dev": "npm -C examples/vite-vue3 run dev",
|
|
71
|
+
"prepublishOnly": "npm run build",
|
|
72
|
+
"lint": "eslint .",
|
|
73
|
+
"release": "bumpp && npm publish",
|
|
74
|
+
"test": "vitest",
|
|
75
|
+
"test:update": "vitest --u"
|
|
76
|
+
},
|
|
66
77
|
"peerDependencies": {
|
|
67
78
|
"@babel/parser": "^7.15.8",
|
|
68
79
|
"vue": "2 || 3"
|
|
@@ -85,7 +96,7 @@
|
|
|
85
96
|
"unplugin": "^0.7.0"
|
|
86
97
|
},
|
|
87
98
|
"devDependencies": {
|
|
88
|
-
"@antfu/eslint-config": "^0.25.
|
|
99
|
+
"@antfu/eslint-config": "^0.25.2",
|
|
89
100
|
"@babel/parser": "^7.18.5",
|
|
90
101
|
"@babel/types": "^7.18.4",
|
|
91
102
|
"@types/debug": "^4.1.7",
|
|
@@ -104,17 +115,7 @@
|
|
|
104
115
|
"tsup": "^6.1.2",
|
|
105
116
|
"typescript": "^4.7.4",
|
|
106
117
|
"vite": "^2.9.12",
|
|
107
|
-
"vitest": "^0.
|
|
118
|
+
"vitest": "^0.16.0",
|
|
108
119
|
"vue": "3.2.37"
|
|
109
|
-
},
|
|
110
|
-
"scripts": {
|
|
111
|
-
"build": "tsup && esno scripts/postbuild.ts",
|
|
112
|
-
"dev": "tsup --watch src",
|
|
113
|
-
"example:build": "npm -C examples/vite-vue3 run build",
|
|
114
|
-
"example:dev": "npm -C examples/vite-vue3 run dev",
|
|
115
|
-
"lint": "eslint .",
|
|
116
|
-
"release": "bumpp --commit --tag --push",
|
|
117
|
-
"test": "vitest",
|
|
118
|
-
"test:update": "vitest --u"
|
|
119
120
|
}
|
|
120
|
-
}
|
|
121
|
+
}
|