@unocss/vite 0.31.2 → 0.31.6

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 CHANGED
@@ -659,6 +659,9 @@ function initTransformerPlugins(ctx) {
659
659
  name: "unocss:transformers:default",
660
660
  transform(code, id) {
661
661
  return applyTransformers(code, id);
662
+ },
663
+ transformIndexHtml(code) {
664
+ return applyTransformers(code, "index.html").then((t) => t?.code);
662
665
  }
663
666
  },
664
667
  {
@@ -666,6 +669,9 @@ function initTransformerPlugins(ctx) {
666
669
  enforce: "pre",
667
670
  transform(code, id) {
668
671
  return applyTransformers(code, id, "pre");
672
+ },
673
+ transformIndexHtml(code) {
674
+ return applyTransformers(code, "index.html", "pre").then((t) => t?.code);
669
675
  }
670
676
  },
671
677
  {
@@ -673,6 +679,9 @@ function initTransformerPlugins(ctx) {
673
679
  enforce: "post",
674
680
  transform(code, id) {
675
681
  return applyTransformers(code, id, "post");
682
+ },
683
+ transformIndexHtml(code) {
684
+ applyTransformers(code, "index.html", "post").then((t) => t?.code);
676
685
  }
677
686
  }
678
687
  ];
package/dist/index.mjs CHANGED
@@ -649,6 +649,9 @@ function initTransformerPlugins(ctx) {
649
649
  name: "unocss:transformers:default",
650
650
  transform(code, id) {
651
651
  return applyTransformers(code, id);
652
+ },
653
+ transformIndexHtml(code) {
654
+ return applyTransformers(code, "index.html").then((t) => t?.code);
652
655
  }
653
656
  },
654
657
  {
@@ -656,6 +659,9 @@ function initTransformerPlugins(ctx) {
656
659
  enforce: "pre",
657
660
  transform(code, id) {
658
661
  return applyTransformers(code, id, "pre");
662
+ },
663
+ transformIndexHtml(code) {
664
+ return applyTransformers(code, "index.html", "pre").then((t) => t?.code);
659
665
  }
660
666
  },
661
667
  {
@@ -663,6 +669,9 @@ function initTransformerPlugins(ctx) {
663
669
  enforce: "post",
664
670
  transform(code, id) {
665
671
  return applyTransformers(code, id, "post");
672
+ },
673
+ transformIndexHtml(code) {
674
+ applyTransformers(code, "index.html", "post").then((t) => t?.code);
666
675
  }
667
676
  }
668
677
  ];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@unocss/vite",
3
- "version": "0.31.2",
3
+ "version": "0.31.6",
4
4
  "description": "The Vite plugin for UnoCSS",
5
5
  "keywords": [
6
6
  "unocss",
@@ -42,16 +42,16 @@
42
42
  "vite": "^2.9.0"
43
43
  },
44
44
  "dependencies": {
45
- "@rollup/pluginutils": "^4.2.0",
46
- "@unocss/config": "0.31.2",
47
- "@unocss/core": "0.31.2",
48
- "@unocss/inspector": "0.31.2",
49
- "@unocss/scope": "0.31.2",
50
- "@unocss/transformer-directives": "0.31.2",
45
+ "@rollup/pluginutils": "^4.2.1",
46
+ "@unocss/config": "0.31.6",
47
+ "@unocss/core": "0.31.6",
48
+ "@unocss/inspector": "0.31.6",
49
+ "@unocss/scope": "0.31.6",
50
+ "@unocss/transformer-directives": "0.31.6",
51
51
  "magic-string": "^0.26.1"
52
52
  },
53
53
  "devDependencies": {
54
- "vite": "^2.9.1"
54
+ "vite": "^2.9.5"
55
55
  },
56
56
  "scripts": {
57
57
  "build": "unbuild",