mirror of
https://github.com/NovaGM/ModuleBuilder.git
synced 2024-08-15 00:23:33 +00:00
[PCPlugin] Replace exports and add new
This commit is contained in:
parent
3f46914b3f
commit
9ae7e3260f
1 changed files with 1 additions and 1 deletions
|
@ -19,7 +19,7 @@ export default (manifestPath, repo) => {
|
|||
|
||||
const content = readFileSync(pcManifest.main || 'index.js', 'utf8');//.replace(/\\/g, '\\\\').replace(/`/g, '\\`');
|
||||
|
||||
const jsCode = content;
|
||||
const jsCode = content.replace(`module.exports = class`, `export default new class`);
|
||||
|
||||
writeFileSync(`${manifestPath}/goosemodModule.json`, JSON.stringify(manifest));
|
||||
writeFileSync(`${manifestPath}/index.js`, jsCode);
|
||||
|
|
Loading…
Reference in a new issue