naive-ui/scripts/gen-version.js
2024-07-12 02:19:13 +08:00

7 lines
192 B
JavaScript

const version = require('../package.json').version
require('node:fs').writeFileSync(
require('node:path').resolve(__dirname, '..', 'src', 'version.ts'),
`export default '${version}'\n`
)