const TransformPages = require('uni-read-pages')
transpileDependencies: ['z-paging']
const {
	webpack
} = new TransformPages()
module.exports = {
	configureWebpack: {
		plugins: [
			new webpack.DefinePlugin({
				ROUTES: webpack.DefinePlugin.runtimeValue(() => {
					const tfPages = new TransformPages({
						includes: ['path', 'name', 'aliasPath', 'meta']
					});
					return JSON.stringify(tfPages.routes)
				}, true)
			})
		]
	},
	devServer: {
		proxy: {
			'/addons': {
				target: 'http://nywhcm.com',
				// pathRewrite: {
				// 	'^/prefix': ''
				// }
			}
		},
	}
}