init
This commit is contained in:
@@ -4,7 +4,7 @@ import devConfig from './dev'
|
||||
import prodConfig from './prod'
|
||||
|
||||
// https://taro-docs.jd.com/docs/next/config#defineconfig-辅助函数
|
||||
export default defineConfig(async (merge, { command, mode }) => {
|
||||
export default defineConfig(async (merge, {}) => {
|
||||
const baseConfig: UserConfigExport = {
|
||||
projectName: 'newGameHome',
|
||||
date: '2023-8-29',
|
||||
@@ -29,7 +29,7 @@ export default defineConfig(async (merge, { command, mode }) => {
|
||||
framework: 'vue3',
|
||||
compiler: 'webpack5',
|
||||
cache: {
|
||||
enable: false // Webpack 持久化缓存配置,建议开启。默认配置请参考:https://docs.taro.zone/docs/config-detail#cache
|
||||
enable: true // Webpack 持久化缓存配置,建议开启。默认配置请参考:https://docs.taro.zone/docs/config-detail#cache
|
||||
},
|
||||
mini: {
|
||||
postcss: {
|
||||
@@ -60,6 +60,9 @@ export default defineConfig(async (merge, { command, mode }) => {
|
||||
h5: {
|
||||
publicPath: '/',
|
||||
staticDirectory: 'static',
|
||||
router: {
|
||||
mode: 'browser'
|
||||
},
|
||||
output: {
|
||||
filename: 'js/[name].[hash:8].js',
|
||||
chunkFilename: 'js/[name].[chunkhash:8].js'
|
||||
@@ -75,7 +78,7 @@ export default defineConfig(async (merge, { command, mode }) => {
|
||||
config: {}
|
||||
},
|
||||
cssModules: {
|
||||
enable: false, // 默认为 false,如需使用 css modules 功能,则设为 true
|
||||
enable: true, // 默认为 false,如需使用 css modules 功能,则设为 true
|
||||
config: {
|
||||
namingPattern: 'module', // 转换模式,取值为 global/module
|
||||
generateScopedName: '[name]__[local]___[hash:base64:5]'
|
||||
|
||||
Reference in New Issue
Block a user