kirbyup 3.1.5 → 3.1.7

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/node/cli.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  import { cac } from 'cac';
2
- import { n as name, b as build, s as serve, v as version, h as handleError } from '../shared/kirbyup.DKFIHHbk.mjs';
2
+ import { n as name, b as build, s as serve, v as version, h as handleError } from '../shared/kirbyup.DDJeIriK.mjs';
3
3
  import 'node:fs';
4
4
  import 'node:fs/promises';
5
5
  import 'pathe';
@@ -10,7 +10,7 @@ import '@vitejs/plugin-vue2';
10
10
  import '@vitejs/plugin-vue2-jsx';
11
11
  import 'vite-plugin-full-reload';
12
12
  import 'rollup-plugin-external-globals';
13
- export { b as build, s as serve } from '../shared/kirbyup.DKFIHHbk.mjs';
13
+ export { b as build, s as serve } from '../shared/kirbyup.DDJeIriK.mjs';
14
14
  import 'node:zlib';
15
15
  import 'node:util';
16
16
  import 'node:buffer';
@@ -21,7 +21,7 @@ import MagicString from 'magic-string';
21
21
  import 'node:module';
22
22
 
23
23
  const name = "kirbyup";
24
- const version = "3.1.5";
24
+ const version = "3.1.7";
25
25
 
26
26
  class PrettyError extends Error {
27
27
  constructor(message) {
@@ -82,7 +82,7 @@ async function resolvePostCSSConfig(cwd) {
82
82
  }
83
83
  }
84
84
 
85
- const multilineCommentsRE = /\/\*(.|[\r\n])*?\*\//gm;
85
+ const multilineCommentsRE = /\/\*(.|[\r\n])*?\*\//g;
86
86
  const singlelineCommentsRE = /\/\/.*/g;
87
87
  const HMR_RUNTIME_ID = "\0plugin-vue2:hmr-runtime";
88
88
  const JSX_HMR_RUNTIME_ID = "plugin-vue2-jsx:hmr-runtime";
@@ -359,7 +359,7 @@ function getViteConfig(command, options) {
359
359
  const aliasDir = resolve(options.cwd, dirname(options.entry));
360
360
  const { alias = {}, vite, extendViteConfig } = resolvedKirbyupConfig;
361
361
  const userConfig = vite ?? extendViteConfig ?? {};
362
- const baseConfig = {
362
+ const sharedConfig = {
363
363
  resolve: {
364
364
  alias: {
365
365
  "~/": `${aliasDir}/`,
@@ -381,7 +381,7 @@ function getViteConfig(command, options) {
381
381
  };
382
382
  if (command === "serve") {
383
383
  const { port, watch } = options;
384
- const serveConfig = mergeConfig(baseConfig, {
384
+ const serveConfig = mergeConfig(sharedConfig, {
385
385
  plugins: [
386
386
  kirbyupHmrPlugin(options),
387
387
  watch && fullReloadPlugin(watch)
@@ -394,7 +394,7 @@ function getViteConfig(command, options) {
394
394
  return mergeConfig(serveConfig, userConfig);
395
395
  }
396
396
  const mode = options.watch ? "development" : "production";
397
- const buildConfig = mergeConfig(baseConfig, {
397
+ const buildConfig = mergeConfig(sharedConfig, {
398
398
  plugins: [kirbyupBuildCleanupPlugin(options)],
399
399
  mode,
400
400
  build: {
@@ -448,7 +448,7 @@ async function generate(options) {
448
448
  return result;
449
449
  }
450
450
  async function build(options) {
451
- ensureEntry(options);
451
+ assertEntryExists(options);
452
452
  const { cwd } = options;
453
453
  const { config, configFile } = await loadConfig(cwd);
454
454
  resolvedKirbyupConfig = config ?? {};
@@ -503,7 +503,7 @@ async function build(options) {
503
503
  startWatcher();
504
504
  }
505
505
  async function serve(options) {
506
- ensureEntry(options);
506
+ assertEntryExists(options);
507
507
  const { cwd } = options;
508
508
  const { config } = await loadConfig(cwd);
509
509
  resolvedKirbyupConfig = config ?? {};
@@ -517,7 +517,7 @@ async function serve(options) {
517
517
  consola.success(`Server is listening on :${server.config.server.port}`);
518
518
  return server;
519
519
  }
520
- function ensureEntry(options) {
520
+ function assertEntryExists(options) {
521
521
  if (!existsSync(resolve(options.cwd, options.entry)))
522
522
  throw new PrettyError(`Cannot find "${options.entry}"`);
523
523
  }
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "kirbyup",
3
3
  "type": "module",
4
- "version": "3.1.5",
5
- "packageManager": "pnpm@8.15.4",
4
+ "version": "3.1.7",
5
+ "packageManager": "pnpm@9.5.0",
6
6
  "description": "Zero-config bundler for Kirby Panel plugins",
7
7
  "author": {
8
8
  "name": "Johann Schopplich",
9
- "email": "pkg@johannschopplich.com",
9
+ "email": "hello@johannschopplich.com",
10
10
  "url": "https://johannschopplich.com"
11
11
  },
12
12
  "license": "MIT",
@@ -26,15 +26,15 @@
26
26
  ],
27
27
  "exports": {
28
28
  ".": {
29
- "types": "./dist/node/index.d.ts",
29
+ "types": "./dist/node/index.d.mts",
30
30
  "import": "./dist/node/index.mjs"
31
31
  },
32
32
  "./config": {
33
- "types": "./dist/client/config.d.ts",
33
+ "types": "./dist/client/config.d.mts",
34
34
  "import": "./dist/client/config.mjs"
35
35
  },
36
36
  "./plugin": {
37
- "types": "./dist/client/plugin.d.ts",
37
+ "types": "./dist/client/plugin.d.mts",
38
38
  "import": "./dist/client/plugin.mjs"
39
39
  }
40
40
  },
@@ -43,10 +43,10 @@
43
43
  "typesVersions": {
44
44
  "*": {
45
45
  "config": [
46
- "./dist/client/config.d.ts"
46
+ "./dist/client/config.d.mts"
47
47
  ],
48
48
  "plugin": [
49
- "./dist/client/plugin.d.ts"
49
+ "./dist/client/plugin.d.mts"
50
50
  ]
51
51
  }
52
52
  },
@@ -68,46 +68,41 @@
68
68
  "lint:fix": "eslint . --fix",
69
69
  "release": "bumpp --commit --push --tag",
70
70
  "test": "vitest --no-isolate",
71
- "test:types": "tsc --noEmit",
72
- "prepare": "simple-git-hooks"
71
+ "test:types": "tsc --noEmit"
73
72
  },
74
73
  "dependencies": {
75
74
  "@vitejs/plugin-vue2": "2.2.0",
76
75
  "@vitejs/plugin-vue2-jsx": "1.1.0",
77
76
  "@vue/compiler-sfc": "^2.7.16",
78
- "c12": "^1.10.0",
77
+ "c12": "^1.11.1",
79
78
  "cac": "^6.7.14",
80
79
  "chokidar": "^3.6.0",
81
80
  "consola": "^3.2.3",
82
- "magic-string": "^0.30.8",
81
+ "magic-string": "^0.30.10",
83
82
  "pathe": "^1.1.2",
84
83
  "perfect-debounce": "^1.0.0",
85
- "postcss": "^8.4.35",
84
+ "postcss": "^8.4.39",
86
85
  "postcss-dir-pseudo-class": "^8.0.1",
87
- "postcss-load-config": "^5.0.3",
86
+ "postcss-load-config": "^5.1.0",
88
87
  "postcss-logical": "^7.0.1",
89
- "rollup-plugin-external-globals": "^0.9.2",
90
- "sass": "^1.71.1",
91
- "vite": "^5.1.6",
92
- "vite-plugin-full-reload": "^1.1.0",
88
+ "rollup-plugin-external-globals": "^0.11.0",
89
+ "sass": "^1.77.7",
90
+ "vite": "~5.3.3",
91
+ "vite-plugin-full-reload": "^1.2.0",
93
92
  "vue": "^2.7.16"
94
93
  },
95
94
  "devDependencies": {
96
- "@antfu/eslint-config": "^2.8.0",
95
+ "@antfu/eslint-config": "^2.22.0",
97
96
  "@types/fs-extra": "^11.0.4",
98
- "@types/node": "^20.11.25",
97
+ "@types/node": "^20.14.10",
99
98
  "@types/prompts": "^2.4.9",
100
- "bumpp": "^9.4.0",
101
- "eslint": "^8.57.0",
99
+ "bumpp": "^9.4.1",
100
+ "eslint": "^9.6.0",
102
101
  "fast-glob": "^3.3.2",
103
102
  "fs-extra": "^11.2.0",
104
- "nypm": "^0.3.8",
105
- "simple-git-hooks": "^2.10.0",
106
- "typescript": "~5.3.3",
107
- "unbuild": "^3.0.0-rc.1",
108
- "vitest": "^1.3.1"
109
- },
110
- "simple-git-hooks": {
111
- "commit-msg": "node scripts/verifyCommit.mjs $1"
103
+ "nypm": "^0.3.9",
104
+ "typescript": "^5.5.3",
105
+ "unbuild": "^3.0.0-rc.6",
106
+ "vitest": "^2.0.1"
112
107
  }
113
108
  }