mirror of
https://github.com/NovaGM/ModuleBuilder.git
synced 2024-08-15 00:23:33 +00:00
[PCPlugin] Tweak replace syntax for default export
This commit is contained in:
parent
c01ba562f3
commit
6c1379811a
1 changed files with 1 additions and 1 deletions
|
@ -20,7 +20,7 @@ export default (manifestPath, repo) => {
|
|||
|
||||
let content = readFileSync(pcManifest.main || 'index.js', 'utf8');//.replace(/\\/g, '\\\\').replace(/`/g, '\\`');
|
||||
|
||||
content = content.replace(`module.exports = class`, `export default new class`);
|
||||
content = content.replace(`module.exports = `, `export default new `);
|
||||
content = content.replace(/this\.loadStylesheet\(['"`](.*)['"`]\)/g, (_, relative) => {
|
||||
const path = manifestPath.split('/').slice(0, -1).concat('').join('/') + relative;
|
||||
|
||||
|
|
Loading…
Reference in a new issue