Skip to content

Commit ca0daa1

Browse files
committed
feat: support dynamic injected env & improve css-loader compat & assets without protocol like http/https
1 parent e2bff0a commit ca0daa1

File tree

3 files changed

+21
-9
lines changed

3 files changed

+21
-9
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
<a name="1.3.6"></a>
2+
## [1.3.6](https://github.com/IndexXuan/vue-cli-plugin-vite/compare/v1.3.5...v1.3.6) (2021-08-09)
3+
4+
5+
16
<a name="1.3.5"></a>
27
## [1.3.5](https://github.com/IndexXuan/vue-cli-plugin-vite/compare/v1.3.4...v1.3.5) (2021-07-06)
38

README.md

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,11 @@ yarn vite // or npm run vite
116116
* @default {}
117117
*/
118118
optimizeDeps: {}
119+
/**
120+
* disabled type-checker, recommended old project disabled it.
121+
* @default false
122+
*/
123+
disabledTypeChecker: false,
119124
}
120125
},
121126
}
@@ -155,7 +160,7 @@ yarn vite // or npm run vite
155160
- ✅ we can do nothing but rewrite corresponding vite-plugin, most code and tools can be reused
156161
- ✅ Environment Variables Compatibility
157162
- ✅ load to process.env.XXX (all env with or without prefix will be loaded)
158-
- ✅ recognize `VUE_APP_` prefix (you can use other instead by config, e.g. `REACT_APP_`)
163+
- ✅ recognize `VUE_APP_` prefix
159164
- ✅ define as `process.env.${PREFIX}_XXX` for client-side
160165
- ✅ Entry Files (we can do nothing)
161166
- ✅ Config File (vue.config.js Options auto-resolved)
@@ -184,6 +189,8 @@ yarn vite // or npm run vite
184189
- ✅ Special Synatax
185190
- ❌ require('xxx') or require('xxx').default, most of the case, it can be replaced by dynamicImport ( import('xxx') or import('xxx').then(module => module.default) )
186191
- ✅ import '~some-module/theme/index.css' syntax for Import CSS [supported by vite#2185](https://github.com/vitejs/vite/issues/2185#issuecomment-784637827))
192+
- ✅ import '~@some-module/theme/index.css' syntax for Import CSS [supported by vite#2185](https://github.com/vitejs/vite/issues/2185#issuecomment-784637827))
193+
-~public & ~/public support
187194
- ✅ require.context compatibility
188195
- ✅ module.hot compatibilite
189196
- ✅ Type Checker
@@ -234,8 +241,8 @@ you can clone/fork this repo, under examples/*
234241
- [vite-plugin-eslint@gxmari007](https://github.com/gxmari007/vite-plugin-eslint) - Eslint for vite.
235242
- [@vitejs/plugin-vue](https://github.com/vitejs/vite/tree/main/packages/plugin-vue) - Official Vue 3 plugin.
236243
- [@vitejs/plugin-vue-jsx](https://github.com/vitejs/vite/tree/main/packages/plugin-vue-jsx) - Official Vue 3 jsx plugin.
237-
- [vite-plugin-env-compatible](https://github.com/IndexXuan/vite-plugin-env-compatible) - Env compatibility for vite with vue-cli.
238-
- [vite-plugin-html-template](https://github.com/IndexXuan/vite-plugin-html-template) - Like html-webpack-plugin for webpack.
239-
- [vite-plugin-vue-cli](https://github.com/IndexXuan/vite-plugin-vue-cli) - Infer vite config from vue.config.js.
240-
- [vite-plugin-mpa](https://github.com/IndexXuan/vite-plugin-mpa) - MPA support for vite.
244+
- [vite-plugin-env-compatible@IndexXuan](https://github.com/IndexXuan/vite-plugin-env-compatible) - Env compatibility for vite with vue-cli.
245+
- [vite-plugin-html-template@IndexXuan](https://github.com/IndexXuan/vite-plugin-html-template) - Like html-webpack-plugin for webpack.
246+
- [vite-plugin-vue-cli@IndexXuan](https://github.com/IndexXuan/vite-plugin-vue-cli) - Infer vite config from vue.config.js.
247+
- [vite-plugin-mpa@IndexXuan](https://github.com/IndexXuan/vite-plugin-mpa) - MPA support for vite.
241248

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vue-cli-plugin-vite",
3-
"version": "1.3.5",
3+
"version": "1.3.6",
44
"description": "out-of-box vite dev for vue-cli project",
55
"main": "index.js",
66
"author": "[email protected]",
@@ -36,11 +36,11 @@
3636
"vite-plugin-checker": "0.2.0",
3737
"vite-plugin-checker-vls": "0.2.1",
3838
"vite-plugin-eslint": "1.3.0",
39-
"vite-plugin-env-compatible": "1.0.0",
39+
"vite-plugin-env-compatible": "1.1.0",
4040
"vite-plugin-html-template": "1.0.4",
4141
"vite-plugin-mpa": "1.0.3",
42-
"vite-plugin-vue-cli": "1.2.1",
43-
"vite-plugin-vue2": "1.7.2",
42+
"vite-plugin-vue-cli": "1.3.1",
43+
"vite-plugin-vue2-plus": "1.7.4-rc.1",
4444
"cross-spawn": "7.0.3",
4545
"semver": "7.3.5",
4646
"chalk": "4.1.0"

0 commit comments

Comments
 (0)