weapp-vite 1.0.0 → 1.0.1
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/config.cjs +32 -0
- package/dist/config.d.cts +15 -0
- package/dist/config.d.ts +15 -0
- package/dist/config.js +7 -0
- package/dist/index.d.cts +2 -16
- package/dist/index.d.ts +2 -16
- package/dist/types-zERbFVBd.d.cts +18 -0
- package/dist/types-zERbFVBd.d.ts +18 -0
- package/package.json +6 -5
package/dist/config.cjs
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/config.ts
|
|
21
|
+
var config_exports = {};
|
|
22
|
+
__export(config_exports, {
|
|
23
|
+
defineConfig: () => defineConfig
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(config_exports);
|
|
26
|
+
function defineConfig(config) {
|
|
27
|
+
return config;
|
|
28
|
+
}
|
|
29
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
30
|
+
0 && (module.exports = {
|
|
31
|
+
defineConfig
|
|
32
|
+
});
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { UserConfig, UserConfigFnObject, UserConfigExport } from 'vite';
|
|
2
|
+
export { UserConfig, UserConfigExport, UserConfigFnObject } from 'vite';
|
|
3
|
+
import { W as WeappViteConfig } from './types-zERbFVBd.cjs';
|
|
4
|
+
|
|
5
|
+
declare module 'vite' {
|
|
6
|
+
interface UserConfig {
|
|
7
|
+
weapp?: WeappViteConfig;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
declare function defineConfig(config: UserConfig): UserConfig;
|
|
11
|
+
declare function defineConfig(config: Promise<UserConfig>): Promise<UserConfig>;
|
|
12
|
+
declare function defineConfig(config: UserConfigFnObject): UserConfigFnObject;
|
|
13
|
+
declare function defineConfig(config: UserConfigExport): UserConfigExport;
|
|
14
|
+
|
|
15
|
+
export { defineConfig };
|
package/dist/config.d.ts
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { UserConfig, UserConfigFnObject, UserConfigExport } from 'vite';
|
|
2
|
+
export { UserConfig, UserConfigExport, UserConfigFnObject } from 'vite';
|
|
3
|
+
import { W as WeappViteConfig } from './types-zERbFVBd.js';
|
|
4
|
+
|
|
5
|
+
declare module 'vite' {
|
|
6
|
+
interface UserConfig {
|
|
7
|
+
weapp?: WeappViteConfig;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
declare function defineConfig(config: UserConfig): UserConfig;
|
|
11
|
+
declare function defineConfig(config: Promise<UserConfig>): Promise<UserConfig>;
|
|
12
|
+
declare function defineConfig(config: UserConfigFnObject): UserConfigFnObject;
|
|
13
|
+
declare function defineConfig(config: UserConfigExport): UserConfigExport;
|
|
14
|
+
|
|
15
|
+
export { defineConfig };
|
package/dist/config.js
ADDED
package/dist/index.d.cts
CHANGED
|
@@ -1,21 +1,7 @@
|
|
|
1
1
|
import { RollupWatcher, EmittedFile, RollupOutput } from 'rollup';
|
|
2
|
-
import {
|
|
2
|
+
import { U as UserConfig } from './types-zERbFVBd.cjs';
|
|
3
3
|
import { FSWatcher } from 'chokidar';
|
|
4
|
-
|
|
5
|
-
interface Subpackage {
|
|
6
|
-
pages: string[];
|
|
7
|
-
root: string;
|
|
8
|
-
independent?: boolean;
|
|
9
|
-
entry?: string;
|
|
10
|
-
name?: string;
|
|
11
|
-
}
|
|
12
|
-
interface WeappViteConfig {
|
|
13
|
-
srcRoot?: string;
|
|
14
|
-
subPackage?: Partial<Subpackage>;
|
|
15
|
-
}
|
|
16
|
-
type UserConfig = UserConfig$1 & {
|
|
17
|
-
weapp?: WeappViteConfig;
|
|
18
|
-
};
|
|
4
|
+
import 'vite';
|
|
19
5
|
|
|
20
6
|
declare function createContext(): {
|
|
21
7
|
watcherCache: Map<string | symbol, RollupWatcher | FSWatcher>;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,21 +1,7 @@
|
|
|
1
1
|
import { RollupWatcher, EmittedFile, RollupOutput } from 'rollup';
|
|
2
|
-
import {
|
|
2
|
+
import { U as UserConfig } from './types-zERbFVBd.js';
|
|
3
3
|
import { FSWatcher } from 'chokidar';
|
|
4
|
-
|
|
5
|
-
interface Subpackage {
|
|
6
|
-
pages: string[];
|
|
7
|
-
root: string;
|
|
8
|
-
independent?: boolean;
|
|
9
|
-
entry?: string;
|
|
10
|
-
name?: string;
|
|
11
|
-
}
|
|
12
|
-
interface WeappViteConfig {
|
|
13
|
-
srcRoot?: string;
|
|
14
|
-
subPackage?: Partial<Subpackage>;
|
|
15
|
-
}
|
|
16
|
-
type UserConfig = UserConfig$1 & {
|
|
17
|
-
weapp?: WeappViteConfig;
|
|
18
|
-
};
|
|
4
|
+
import 'vite';
|
|
19
5
|
|
|
20
6
|
declare function createContext(): {
|
|
21
7
|
watcherCache: Map<string | symbol, RollupWatcher | FSWatcher>;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { UserConfig as UserConfig$1 } from 'vite';
|
|
2
|
+
|
|
3
|
+
interface Subpackage {
|
|
4
|
+
pages: string[];
|
|
5
|
+
root: string;
|
|
6
|
+
independent?: boolean;
|
|
7
|
+
entry?: string;
|
|
8
|
+
name?: string;
|
|
9
|
+
}
|
|
10
|
+
interface WeappViteConfig {
|
|
11
|
+
srcRoot?: string;
|
|
12
|
+
subPackage?: Partial<Subpackage>;
|
|
13
|
+
}
|
|
14
|
+
type UserConfig = UserConfig$1 & {
|
|
15
|
+
weapp?: WeappViteConfig;
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
export type { UserConfig as U, WeappViteConfig as W };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { UserConfig as UserConfig$1 } from 'vite';
|
|
2
|
+
|
|
3
|
+
interface Subpackage {
|
|
4
|
+
pages: string[];
|
|
5
|
+
root: string;
|
|
6
|
+
independent?: boolean;
|
|
7
|
+
entry?: string;
|
|
8
|
+
name?: string;
|
|
9
|
+
}
|
|
10
|
+
interface WeappViteConfig {
|
|
11
|
+
srcRoot?: string;
|
|
12
|
+
subPackage?: Partial<Subpackage>;
|
|
13
|
+
}
|
|
14
|
+
type UserConfig = UserConfig$1 & {
|
|
15
|
+
weapp?: WeappViteConfig;
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
export type { UserConfig as U, WeappViteConfig as W };
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "weapp-vite",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.0.
|
|
5
|
-
"description": "
|
|
4
|
+
"version": "1.0.1",
|
|
5
|
+
"description": "weapp-vite 一个现代化的小程序打包工具",
|
|
6
6
|
"author": "SonOfMagic <qq1324318532@gmail.com>",
|
|
7
7
|
"license": "MIT",
|
|
8
8
|
"repository": {
|
|
@@ -45,9 +45,9 @@
|
|
|
45
45
|
"pathe": "^1.1.2",
|
|
46
46
|
"pkg-types": "^1.1.3",
|
|
47
47
|
"@weapp-core/init": "^1.0.0",
|
|
48
|
-
"@weapp-core/logger": "^1.0.0",
|
|
49
48
|
"@weapp-core/shared": "^1.0.0",
|
|
50
|
-
"weapp-ide-cli": "^2.0.0"
|
|
49
|
+
"weapp-ide-cli": "^2.0.0",
|
|
50
|
+
"@weapp-core/logger": "^1.0.0"
|
|
51
51
|
},
|
|
52
52
|
"publishConfig": {
|
|
53
53
|
"access": "public",
|
|
@@ -58,7 +58,8 @@
|
|
|
58
58
|
"build": "tsup",
|
|
59
59
|
"release": "node scripts/release.js",
|
|
60
60
|
"test:dev": "vitest",
|
|
61
|
-
"test": "vitest run"
|
|
61
|
+
"test": "vitest run",
|
|
62
|
+
"sync": "cnpm sync weapp-vite"
|
|
62
63
|
},
|
|
63
64
|
"main": "./dist/index.cjs",
|
|
64
65
|
"module": "./dist/index.js",
|