- Maven modules: openhis-* → healthlink-his-* - Java packages: com.openhis → com.healthlink.his (3,278 files) - Configuration: context-path, DB schema, logger, package scan - Frontend: API paths /openhis/ → /healthlink-his/ (30 files) - Database: healthlink_his schema with 188 tables (copied from hisdev) - Verified: 18/18 API tests passed, 10-concurrent smoke test passed
29 lines
881 B
JavaScript
Executable File
29 lines
881 B
JavaScript
Executable File
import compression from 'vite-plugin-compression'
|
|
|
|
export default function createCompression(env) {
|
|
const { VITE_BUILD_COMPRESS } = env
|
|
const plugin = []
|
|
if (VITE_BUILD_COMPRESS) {
|
|
const compressList = VITE_BUILD_COMPRESS.split(',')
|
|
if (compressList.includes('gzip')) {
|
|
// http://doc.healthlink-hisis.vip/healthlink-his-vue/other/faq.html#使用gzip解压缩静态文件
|
|
plugin.push(
|
|
compression({
|
|
ext: '.gz',
|
|
deleteOriginFile: false
|
|
})
|
|
)
|
|
}
|
|
if (compressList.includes('brotli')) {
|
|
plugin.push(
|
|
compression({
|
|
ext: '.br',
|
|
algorithm: 'brotliCompress',
|
|
deleteOriginFile: false
|
|
})
|
|
)
|
|
}
|
|
}
|
|
return plugin
|
|
}
|