Skip to content

Commit

Permalink
feat: support vite v4 and v5
Browse files Browse the repository at this point in the history
  • Loading branch information
greenhat616 committed Nov 12, 2023
1 parent 0f35d30 commit 9431453
Show file tree
Hide file tree
Showing 7 changed files with 1,318 additions and 3,693 deletions.
11 changes: 11 additions & 0 deletions build.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import { defineBuildConfig } from "unbuild";

export default defineBuildConfig({
entries: ["src/index"],
clean: true,
declaration: true,
rollup: {
emitCJS: true,
inlineDependencies: true,
},
});
43 changes: 24 additions & 19 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,46 +3,51 @@
"version": "0.4.7",
"description": "A vite plugin for better chunk split",
"author": "sanyuan0704",
"main": "dist/index.js",
"type": "module",
"exports": {
".": {
"import": "./dist/index.mjs",
"require": "./dist/index.cjs"
}
},
"main": "./dist/index.cjs",
"types": "./dist/index.d.ts",
"files": [
"dist"
],
"repository": {
"url": "git+ssh://git@github.com/sanyuan0704/vite-plugin-chunk-split.git"
},
"scripts": {
"build": "tsc",
"start": "tsc -w",
"dev": "unbuild --stub",
"build": "unbuild",
"prepublishOnly": "npm run build",
"test": "vitest run"
},
"keywords": [
"vite",
"code-splitting"
],
"files": [
"dist"
],
"license": "MIT",
"devDependencies": {
"@types/jest": "^27.0.1",
"@types/node": "^17.0.18",
"@types/resolve": "^1.20.1",
"esbuild": "^0.16.1",
"esbuild-jest": "^0.5.0",
"jest": "^27.5.1",
"rollup": "^2.62.0",
"typescript": "^4.5.2",
"vite": "^3.1.0",
"vitest": "^0.25.5"
"@types/node": "^18.18.9",
"@types/resolve": "^1.20.5",
"rollup": "^4.4.0",
"typescript": "^5.2.2",
"unbuild": "^2.0.0",
"vite": "5.0.0-beta.18",
"vitest": "1.0.0-beta.4"
},
"bugs": {
"url": "https://github.com/sanyuan0704/vite-plugin-chunk-split/issues"
},
"homepage": "https://github.com/sanyuan0704/vite-plugin-chunk-split#readme",
"dependencies": {
"es-module-lexer": "^1.0.3",
"magic-string": "^0.26.3"
"es-module-lexer": "^1.4.1",
"import-meta-resolve": "^4.0.0",
"magic-string": "^0.30.5"
},
"peerDependencies": {
"vite": "^3.1.0"
"vite": "^4 || ^5"
}
}

0 comments on commit 9431453

Please sign in to comment.