mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
feat: using mjs entry for sub packages (#10626)
This commit is contained in:
parent
173a364dae
commit
90deb2439f
@ -3,7 +3,7 @@
|
|||||||
"version": "1.2.4",
|
"version": "1.2.4",
|
||||||
"description": "Vant 省市区数据",
|
"description": "Vant 省市区数据",
|
||||||
"main": "dist/index.cjs.js",
|
"main": "dist/index.cjs.js",
|
||||||
"module": "dist/index.esm.js",
|
"module": "dist/index.esm.mjs",
|
||||||
"types": "dist/index.d.ts",
|
"types": "dist/index.d.ts",
|
||||||
"files": [
|
"files": [
|
||||||
"dist"
|
"dist"
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
"version": "1.1.0",
|
"version": "1.1.0",
|
||||||
"description": "Pre-compiled popperjs core",
|
"description": "Pre-compiled popperjs core",
|
||||||
"main": "dist/index.cjs.js",
|
"main": "dist/index.cjs.js",
|
||||||
"module": "dist/index.esm.js",
|
"module": "dist/index.esm.mjs",
|
||||||
"types": "dist/index.d.ts",
|
"types": "dist/index.d.ts",
|
||||||
"sideEffects": false,
|
"sideEffects": false,
|
||||||
"files": [
|
"files": [
|
||||||
|
@ -1,7 +1,8 @@
|
|||||||
const { build } = require('esbuild');
|
const { build } = require('esbuild');
|
||||||
|
|
||||||
function bundleBundle(format) {
|
function bundleBundle(format) {
|
||||||
const outfile = `dist/index.${format}.js`;
|
const ext = format === 'esm' ? '.mjs' : '.js';
|
||||||
|
const outfile = `dist/index.${format}${ext}`;
|
||||||
const finish = () => console.log('Build finished:', outfile);
|
const finish = () => console.log('Build finished:', outfile);
|
||||||
const onRebuild = (error) => (error ? console.log(error) : finish());
|
const onRebuild = (error) => (error ? console.log(error) : finish());
|
||||||
|
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
"version": "1.3.6",
|
"version": "1.3.6",
|
||||||
"description": "Vant Composition API",
|
"description": "Vant Composition API",
|
||||||
"main": "dist/index.cjs.js",
|
"main": "dist/index.cjs.js",
|
||||||
"module": "dist/index.esm.js",
|
"module": "dist/index.esm.mjs",
|
||||||
"typings": "dist/index.d.ts",
|
"typings": "dist/index.d.ts",
|
||||||
"sideEffects": false,
|
"sideEffects": false,
|
||||||
"files": [
|
"files": [
|
||||||
|
Loading…
x
Reference in New Issue
Block a user