silgi 0.1.2 → 0.1.4

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.
@@ -3,29 +3,42 @@ import consola from 'consola';
3
3
 
4
4
  const name = "silgi";
5
5
  const type = "module";
6
- const version = "0.1.2";
6
+ const version = "0.1.3";
7
7
  const packageManager = "pnpm@9.15.1";
8
8
  const exports = {
9
9
  ".": {
10
10
  "import": {
11
- types: "./dist/index.d.ts",
11
+ types: "./dist/index.d.mts",
12
12
  "default": "./dist/index.mjs"
13
13
  }
14
14
  },
15
15
  "./config": {
16
- types: "./dist/cli/config.d.ts",
16
+ types: "./dist/cli/config.d.mts",
17
17
  "import": "./dist/cli/config.mjs"
18
18
  },
19
19
  "./ecosystem/nitro": {
20
- types: "./dist/ecosystem/nitro/module.d.ts",
20
+ types: "./dist/ecosystem/nitro/module.d.mts",
21
21
  "import": "./dist/ecosystem/nitro/module.mjs"
22
22
  },
23
- "./ecosystem/nitro/module": {
24
- types: "./dist/ecosystem/nitro/module.d.ts",
25
- "import": "./dist/ecosystem/nitro/module.mjs"
23
+ "./nuxt": {
24
+ types: "./dist/ecosystem/nuxt/module.d.mts",
25
+ "import": "./dist/ecosystem/nuxt/module.mjs"
26
26
  }
27
27
  };
28
28
  const types = "./dist/index.d.ts";
29
+ const typesVersions = {
30
+ "*": {
31
+ "*": [
32
+ "./dist/*"
33
+ ],
34
+ "modules/*": [
35
+ "./dist/modules/*"
36
+ ],
37
+ config: [
38
+ "./dist/cli/config"
39
+ ]
40
+ }
41
+ };
29
42
  const bin = {
30
43
  silgi: "bin/silgi.mjs"
31
44
  };
@@ -79,6 +92,7 @@ const dependencies = {
79
92
  zod: "^3.24.1"
80
93
  };
81
94
  const devDependencies = {
95
+ "@nuxt/kit": "^3.15.3",
82
96
  "@types/node": "^22.10.7",
83
97
  "@types/semver": "^7.5.8",
84
98
  h3: "^1.14.0",
@@ -96,6 +110,7 @@ const packageJson = {
96
110
  packageManager: packageManager,
97
111
  exports: exports,
98
112
  types: types,
113
+ typesVersions: typesVersions,
99
114
  bin: bin,
100
115
  files: files,
101
116
  scripts: scripts,
@@ -5,6 +5,6 @@ declare module 'nitropack' {
5
5
  }
6
6
  }
7
7
  declare function nitroModule(nitro: Nitro): Promise<void>;
8
- declare function nitroSilgi(arg1: unknown, arg2: unknown): void;
8
+ declare function nitroSilgi(arg1: unknown): void;
9
9
 
10
10
  export { nitroSilgi as default, nitroModule };
@@ -5,6 +5,6 @@ declare module 'nitropack' {
5
5
  }
6
6
  }
7
7
  declare function nitroModule(nitro: Nitro): Promise<void>;
8
- declare function nitroSilgi(arg1: unknown, arg2: unknown): void;
8
+ declare function nitroSilgi(arg1: unknown): void;
9
9
 
10
10
  export { nitroSilgi as default, nitroModule };
@@ -51,15 +51,8 @@ async function nitroModule(nitro) {
51
51
  await nitro.unimport?.init();
52
52
  }
53
53
  }
54
- function nitroSilgi(arg1, arg2) {
55
- if (arg2?.options?.nitro) {
56
- arg2.hooks.hookOnce("nitro:config", (nitroConfig) => {
57
- nitroConfig.modules = nitroConfig.modules || [];
58
- nitroConfig.modules.push(nitroModule);
59
- });
60
- } else {
61
- nitroModule(arg1);
62
- }
54
+ function nitroSilgi(arg1) {
55
+ nitroModule(arg1);
63
56
  }
64
57
 
65
58
  export { nitroSilgi as default, nitroModule };
@@ -0,0 +1,7 @@
1
+ import * as _nuxt_schema from '@nuxt/schema';
2
+
3
+ interface ModuleOptions {
4
+ }
5
+ declare const _default: _nuxt_schema.NuxtModule<ModuleOptions, ModuleOptions, false>;
6
+
7
+ export { type ModuleOptions, _default as default };
@@ -0,0 +1,7 @@
1
+ import * as _nuxt_schema from '@nuxt/schema';
2
+
3
+ interface ModuleOptions {
4
+ }
5
+ declare const _default: _nuxt_schema.NuxtModule<ModuleOptions, ModuleOptions, false>;
6
+
7
+ export { type ModuleOptions, _default as default };
@@ -0,0 +1,44 @@
1
+ import { defineNuxtModule } from '@nuxt/kit';
2
+ import { nitroModule } from '../nitro/module.mjs';
3
+ import 'node:url';
4
+ import 'pathe';
5
+ import 'consola';
6
+ import 'defu';
7
+ import 'hookable';
8
+ import 'untyped';
9
+ import '../../shared/silgi.wK7ZsagJ.mjs';
10
+ import 'unctx';
11
+ import 'std-env';
12
+ import 'semver/functions/satisfies.js';
13
+ import 'node:fs';
14
+ import 'h3';
15
+ import 'node:buffer';
16
+ import 'klona';
17
+ import 'unstorage';
18
+ import 'unstorage/drivers/memory';
19
+ import 'mlly';
20
+ import 'pathe/utils';
21
+ import '../../shared/silgi.KTm2r-Fb.mjs';
22
+ import 'c12';
23
+
24
+ const module = defineNuxtModule({
25
+ meta: {
26
+ name: "silgi",
27
+ configKey: "silgi",
28
+ compatibility: {
29
+ nuxt: ">=3.14"
30
+ }
31
+ },
32
+ defaults: {},
33
+ setup(options, nuxt) {
34
+ nuxt.options.build.transpile.push("silgi");
35
+ if (nuxt.options?.nitro) {
36
+ nuxt.hooks.hookOnce("nitro:config", (nitroConfig) => {
37
+ nitroConfig.modules = nitroConfig.modules || [];
38
+ nitroConfig.modules.push(nitroModule);
39
+ });
40
+ }
41
+ }
42
+ });
43
+
44
+ export { module as default };
package/package.json CHANGED
@@ -1,28 +1,41 @@
1
1
  {
2
2
  "name": "silgi",
3
3
  "type": "module",
4
- "version": "0.1.2",
4
+ "version": "0.1.4",
5
5
  "exports": {
6
6
  ".": {
7
7
  "import": {
8
- "types": "./dist/index.d.ts",
8
+ "types": "./dist/index.d.mts",
9
9
  "default": "./dist/index.mjs"
10
10
  }
11
11
  },
12
12
  "./config": {
13
- "types": "./dist/cli/config.d.ts",
13
+ "types": "./dist/cli/config.d.mts",
14
14
  "import": "./dist/cli/config.mjs"
15
15
  },
16
16
  "./ecosystem/nitro": {
17
- "types": "./dist/ecosystem/nitro/module.d.ts",
17
+ "types": "./dist/ecosystem/nitro/module.d.mts",
18
18
  "import": "./dist/ecosystem/nitro/module.mjs"
19
19
  },
20
- "./ecosystem/nitro/module": {
21
- "types": "./dist/ecosystem/nitro/module.d.ts",
22
- "import": "./dist/ecosystem/nitro/module.mjs"
20
+ "./nuxt": {
21
+ "types": "./dist/ecosystem/nuxt/module.d.mts",
22
+ "import": "./dist/ecosystem/nuxt/module.mjs"
23
23
  }
24
24
  },
25
25
  "types": "./dist/index.d.ts",
26
+ "typesVersions": {
27
+ "*": {
28
+ "*": [
29
+ "./dist/*"
30
+ ],
31
+ "modules/*": [
32
+ "./dist/modules/*"
33
+ ],
34
+ "config": [
35
+ "./dist/cli/config"
36
+ ]
37
+ }
38
+ },
26
39
  "bin": {
27
40
  "silgi": "bin/silgi.mjs"
28
41
  },
@@ -63,6 +76,7 @@
63
76
  "zod": "^3.24.1"
64
77
  },
65
78
  "devDependencies": {
79
+ "@nuxt/kit": "^3.15.3",
66
80
  "@types/node": "^22.10.7",
67
81
  "@types/semver": "^7.5.8",
68
82
  "h3": "^1.14.0",