rs-reverse/utils/initGv.js

13 lines
477 B
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

const paths = require('@utils/paths');
const fs = require('fs');
const { init } = require('@src/handler/parser/');
const pkg = require(paths.package);
const logger = require('./logger');
module.exports = (function() {
const tsFullPath = paths.exampleResolve('codes', pkg.tsfile);
logger.debug(`初始化GlobalVarible变量$_ts配置文件${tsFullPath}`);
init(JSON.parse(fs.readFileSync(tsFullPath, 'utf8')));
return require('@src/handler/globalVarible');
})();