unplugin-env 0.1.7 → 0.1.8

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.
@@ -5,7 +5,7 @@
5
5
 
6
6
  import {
7
7
  unpluginFactory
8
- } from "./chunk-BH25AOMD.js";
8
+ } from "./chunk-HSFO6KAC.js";
9
9
 
10
10
  // src/vite.ts
11
11
  import { createVitePlugin } from "unplugin";
@@ -5,7 +5,7 @@
5
5
 
6
6
  import {
7
7
  unpluginFactory
8
- } from "./chunk-BH25AOMD.js";
8
+ } from "./chunk-HSFO6KAC.js";
9
9
 
10
10
  // src/webpack.ts
11
11
  import { createWebpackPlugin } from "unplugin";
@@ -34662,7 +34662,7 @@ async function generateScript(options, mode) {
34662
34662
  const formatCode = import_js_beautify.default.js_beautify(code);
34663
34663
  return {
34664
34664
  code,
34665
- script: ` <script type="text/javascript" src="${fileName}"></script>
34665
+ script: ` <script type="text/javascript" src="/${fileName}"></script>
34666
34666
  </head>`,
34667
34667
  emit: {
34668
34668
  type: "asset",
@@ -35244,7 +35244,7 @@ async function createCompress(options) {
35244
35244
  const output = fs2.createWriteStream(zipFilePath);
35245
35245
  const archive = archiver("zip");
35246
35246
  output.on("close", () => {
35247
- Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer()} bytes)`);
35247
+ Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer() / 1024 / 1024} MB)`);
35248
35248
  resolve2(null);
35249
35249
  });
35250
35250
  archive.on("warning", (err) => {
package/dist/esbuild.cjs CHANGED
@@ -34669,7 +34669,7 @@ async function generateScript(options, mode) {
34669
34669
  const formatCode = import_js_beautify.default.js_beautify(code);
34670
34670
  return {
34671
34671
  code,
34672
- script: ` <script type="text/javascript" src="${fileName}"></script>
34672
+ script: ` <script type="text/javascript" src="/${fileName}"></script>
34673
34673
  </head>`,
34674
34674
  emit: {
34675
34675
  type: "asset",
@@ -35251,7 +35251,7 @@ async function createCompress(options) {
35251
35251
  const output = import_node_fs3.default.createWriteStream(zipFilePath);
35252
35252
  const archive = (0, import_archiver.default)("zip");
35253
35253
  output.on("close", () => {
35254
- Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer()} bytes)`);
35254
+ Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer() / 1024 / 1024} MB)`);
35255
35255
  resolve2(null);
35256
35256
  });
35257
35257
  archive.on("warning", (err) => {
package/dist/esbuild.js CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  import {
7
7
  unpluginFactory
8
- } from "./chunk-BH25AOMD.js";
8
+ } from "./chunk-HSFO6KAC.js";
9
9
 
10
10
  // src/esbuild.ts
11
11
  import { createEsbuildPlugin } from "unplugin";
package/dist/index.cjs CHANGED
@@ -34668,7 +34668,7 @@ async function generateScript(options, mode) {
34668
34668
  const formatCode = import_js_beautify.default.js_beautify(code);
34669
34669
  return {
34670
34670
  code,
34671
- script: ` <script type="text/javascript" src="${fileName}"></script>
34671
+ script: ` <script type="text/javascript" src="/${fileName}"></script>
34672
34672
  </head>`,
34673
34673
  emit: {
34674
34674
  type: "asset",
@@ -35250,7 +35250,7 @@ async function createCompress(options) {
35250
35250
  const output = import_node_fs3.default.createWriteStream(zipFilePath);
35251
35251
  const archive = (0, import_archiver.default)("zip");
35252
35252
  output.on("close", () => {
35253
- Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer()} bytes)`);
35253
+ Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer() / 1024 / 1024} MB)`);
35254
35254
  resolve2(null);
35255
35255
  });
35256
35256
  archive.on("warning", (err) => {
package/dist/index.js CHANGED
@@ -7,7 +7,7 @@ import {
7
7
  src_default,
8
8
  unplugin,
9
9
  unpluginFactory
10
- } from "./chunk-BH25AOMD.js";
10
+ } from "./chunk-HSFO6KAC.js";
11
11
  export {
12
12
  src_default as default,
13
13
  unplugin,
package/dist/nuxt.cjs CHANGED
@@ -34672,7 +34672,7 @@ async function generateScript(options, mode) {
34672
34672
  const formatCode = import_js_beautify.default.js_beautify(code);
34673
34673
  return {
34674
34674
  code,
34675
- script: ` <script type="text/javascript" src="${fileName}"></script>
34675
+ script: ` <script type="text/javascript" src="/${fileName}"></script>
34676
34676
  </head>`,
34677
34677
  emit: {
34678
34678
  type: "asset",
@@ -35254,7 +35254,7 @@ async function createCompress(options) {
35254
35254
  const output = import_node_fs3.default.createWriteStream(zipFilePath);
35255
35255
  const archive = (0, import_archiver.default)("zip");
35256
35256
  output.on("close", () => {
35257
- Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer()} bytes)`);
35257
+ Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer() / 1024 / 1024} MB)`);
35258
35258
  resolve2(null);
35259
35259
  });
35260
35260
  archive.on("warning", (err) => {
package/dist/nuxt.js CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  import {
7
7
  vite_default
8
- } from "./chunk-Q4AFCMOU.js";
8
+ } from "./chunk-D7PHTHAC.js";
9
9
  import {
10
10
  webpack_default
11
- } from "./chunk-NYX6TIRV.js";
12
- import "./chunk-BH25AOMD.js";
11
+ } from "./chunk-FG4FU2UV.js";
12
+ import "./chunk-HSFO6KAC.js";
13
13
 
14
14
  // src/nuxt.ts
15
15
  import { addVitePlugin, addWebpackPlugin, defineNuxtModule } from "@nuxt/kit";
package/dist/rollup.cjs CHANGED
@@ -34669,7 +34669,7 @@ async function generateScript(options, mode) {
34669
34669
  const formatCode = import_js_beautify.default.js_beautify(code);
34670
34670
  return {
34671
34671
  code,
34672
- script: ` <script type="text/javascript" src="${fileName}"></script>
34672
+ script: ` <script type="text/javascript" src="/${fileName}"></script>
34673
34673
  </head>`,
34674
34674
  emit: {
34675
34675
  type: "asset",
@@ -35251,7 +35251,7 @@ async function createCompress(options) {
35251
35251
  const output = import_node_fs3.default.createWriteStream(zipFilePath);
35252
35252
  const archive = (0, import_archiver.default)("zip");
35253
35253
  output.on("close", () => {
35254
- Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer()} bytes)`);
35254
+ Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer() / 1024 / 1024} MB)`);
35255
35255
  resolve2(null);
35256
35256
  });
35257
35257
  archive.on("warning", (err) => {
package/dist/rollup.js CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  import {
7
7
  unpluginFactory
8
- } from "./chunk-BH25AOMD.js";
8
+ } from "./chunk-HSFO6KAC.js";
9
9
 
10
10
  // src/rollup.ts
11
11
  import { createRollupPlugin } from "unplugin";
package/dist/vite.cjs CHANGED
@@ -34669,7 +34669,7 @@ async function generateScript(options, mode) {
34669
34669
  const formatCode = import_js_beautify.default.js_beautify(code);
34670
34670
  return {
34671
34671
  code,
34672
- script: ` <script type="text/javascript" src="${fileName}"></script>
34672
+ script: ` <script type="text/javascript" src="/${fileName}"></script>
34673
34673
  </head>`,
34674
34674
  emit: {
34675
34675
  type: "asset",
@@ -35251,7 +35251,7 @@ async function createCompress(options) {
35251
35251
  const output = import_node_fs3.default.createWriteStream(zipFilePath);
35252
35252
  const archive = (0, import_archiver.default)("zip");
35253
35253
  output.on("close", () => {
35254
- Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer()} bytes)`);
35254
+ Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer() / 1024 / 1024} MB)`);
35255
35255
  resolve2(null);
35256
35256
  });
35257
35257
  archive.on("warning", (err) => {
package/dist/vite.js CHANGED
@@ -5,8 +5,8 @@
5
5
 
6
6
  import {
7
7
  vite_default
8
- } from "./chunk-Q4AFCMOU.js";
9
- import "./chunk-BH25AOMD.js";
8
+ } from "./chunk-D7PHTHAC.js";
9
+ import "./chunk-HSFO6KAC.js";
10
10
  export {
11
11
  vite_default as default
12
12
  };
package/dist/webpack.cjs CHANGED
@@ -34669,7 +34669,7 @@ async function generateScript(options, mode) {
34669
34669
  const formatCode = import_js_beautify.default.js_beautify(code);
34670
34670
  return {
34671
34671
  code,
34672
- script: ` <script type="text/javascript" src="${fileName}"></script>
34672
+ script: ` <script type="text/javascript" src="/${fileName}"></script>
34673
34673
  </head>`,
34674
34674
  emit: {
34675
34675
  type: "asset",
@@ -35251,7 +35251,7 @@ async function createCompress(options) {
35251
35251
  const output = import_node_fs3.default.createWriteStream(zipFilePath);
35252
35252
  const archive = (0, import_archiver.default)("zip");
35253
35253
  output.on("close", () => {
35254
- Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer()} bytes)`);
35254
+ Log.success("Successfully compressed to", `${zipFilePath} (${archive.pointer() / 1024 / 1024} MB)`);
35255
35255
  resolve2(null);
35256
35256
  });
35257
35257
  archive.on("warning", (err) => {
package/dist/webpack.js CHANGED
@@ -5,8 +5,8 @@
5
5
 
6
6
  import {
7
7
  webpack_default
8
- } from "./chunk-NYX6TIRV.js";
9
- import "./chunk-BH25AOMD.js";
8
+ } from "./chunk-FG4FU2UV.js";
9
+ import "./chunk-HSFO6KAC.js";
10
10
  export {
11
11
  webpack_default as default
12
12
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "unplugin-env",
3
3
  "type": "module",
4
- "version": "0.1.7",
4
+ "version": "0.1.8",
5
5
  "packageManager": "pnpm@7.1.1",
6
6
  "description": "Register global imports on demand for Vite and Webpack",
7
7
  "license": "MIT",