Files
banban/banban-mini/config/index.js
HycJack a22fcafea9 新增小程序后端代码,包括数据库、路由、服务层等。
小程序前后端打通,包括登录、注册、绑定设备、查询绑定信息,修改小朋友名称等功能。
2026-04-13 01:54:57 +08:00

62 lines
1.3 KiB
JavaScript

const path = require('path')
module.exports = {
projectName: 'banban-mini',
date: '2025-3-3',
designWidth: 750,
deviceRatio: {
640: 2.34 / 2,
750: 1,
828: 1.81 / 2
},
sourceRoot: 'src',
outputRoot: 'dist',
plugins: [],
defineConstants: {},
copy: {
patterns: [
{ from: 'src/assets/tab-icons', to: 'dist/assets/tab-icons' }
],
options: {}
},
framework: 'react',
mini: {
webpackChain(chain) {
chain.resolve.alias.set('@', path.resolve(__dirname, '../src'))
},
postcss: {
pxtransform: {
enable: true,
config: {}
},
url: {
enable: true,
config: { limit: 1024 }
},
cssModules: {
enable: false,
config: {
namingPattern: 'module',
generateScopedName: '[name]__[local]___[hash:base64:5]'
}
}
}
},
h5: {
publicPath: '/',
staticDirectory: 'static',
webpackChain(chain) {
chain.resolve.alias.set('@', path.resolve(__dirname, '../src'))
},
postcss: {
autoprefixer: { enable: true, config: {} },
cssModules: {
enable: false,
config: {
namingPattern: 'module',
generateScopedName: '[name]__[local]___[hash:base64:5]'
}
}
}
}
}