@unocss/vite 0.27.0 → 0.27.3
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/index.cjs +7 -5
- package/dist/index.mjs +7 -5
- package/package.json +8 -8
package/dist/index.cjs
CHANGED
|
@@ -7,7 +7,7 @@ const pluginutils = require('@rollup/pluginutils');
|
|
|
7
7
|
const config = require('@unocss/config');
|
|
8
8
|
const core = require('@unocss/core');
|
|
9
9
|
const crypto = require('crypto');
|
|
10
|
-
const MagicString = require('magic-string
|
|
10
|
+
const MagicString = require('magic-string');
|
|
11
11
|
|
|
12
12
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e["default"] : e; }
|
|
13
13
|
|
|
@@ -646,10 +646,12 @@ function initTransformerPlugins(ctx) {
|
|
|
646
646
|
}
|
|
647
647
|
await t.transform(s, id, ctx);
|
|
648
648
|
}
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
649
|
+
if (s.hasChanged()) {
|
|
650
|
+
return {
|
|
651
|
+
code: s.toString(),
|
|
652
|
+
map: s.generateMap({ hires: true, source: id })
|
|
653
|
+
};
|
|
654
|
+
}
|
|
653
655
|
}
|
|
654
656
|
return [
|
|
655
657
|
{
|
package/dist/index.mjs
CHANGED
|
@@ -3,7 +3,7 @@ import { createFilter } from '@rollup/pluginutils';
|
|
|
3
3
|
import { createConfigLoader } from '@unocss/config';
|
|
4
4
|
import { createGenerator, BetterMap } from '@unocss/core';
|
|
5
5
|
import { createHash } from 'crypto';
|
|
6
|
-
import MagicString from 'magic-string
|
|
6
|
+
import MagicString from 'magic-string';
|
|
7
7
|
|
|
8
8
|
const regexCssId = /\.(css|postcss|sass|scss|less|stylus|styl)$/;
|
|
9
9
|
const defaultExclude = [regexCssId];
|
|
@@ -637,10 +637,12 @@ function initTransformerPlugins(ctx) {
|
|
|
637
637
|
}
|
|
638
638
|
await t.transform(s, id, ctx);
|
|
639
639
|
}
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
640
|
+
if (s.hasChanged()) {
|
|
641
|
+
return {
|
|
642
|
+
code: s.toString(),
|
|
643
|
+
map: s.generateMap({ hires: true, source: id })
|
|
644
|
+
};
|
|
645
|
+
}
|
|
644
646
|
}
|
|
645
647
|
return [
|
|
646
648
|
{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unocss/vite",
|
|
3
|
-
"version": "0.27.
|
|
3
|
+
"version": "0.27.3",
|
|
4
4
|
"description": "The Vite plugin for UnoCSS",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"unocss",
|
|
@@ -35,15 +35,15 @@
|
|
|
35
35
|
"types": "dist/index.d.ts",
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@rollup/pluginutils": "^4.1.2",
|
|
38
|
-
"@unocss/config": "0.27.
|
|
39
|
-
"@unocss/core": "0.27.
|
|
40
|
-
"@unocss/inspector": "0.27.
|
|
41
|
-
"@unocss/scope": "0.27.
|
|
42
|
-
"@unocss/transformer-directives": "0.27.
|
|
43
|
-
"magic-string
|
|
38
|
+
"@unocss/config": "0.27.3",
|
|
39
|
+
"@unocss/core": "0.27.3",
|
|
40
|
+
"@unocss/inspector": "0.27.3",
|
|
41
|
+
"@unocss/scope": "0.27.3",
|
|
42
|
+
"@unocss/transformer-directives": "0.27.3",
|
|
43
|
+
"magic-string": "^0.26.1"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
|
-
"vite": "^2.8.
|
|
46
|
+
"vite": "^2.8.6"
|
|
47
47
|
},
|
|
48
48
|
"scripts": {
|
|
49
49
|
"build": "unbuild",
|