Browse Source

KERNEL-5364 chore: 给fineui.js加上sourceMap

master
youki 4 years ago
parent
commit
966c1d2954
  1. 11
      lib/postbuild/postbuild.js

11
lib/postbuild/postbuild.js

@ -34,9 +34,12 @@ deleteList.forEach(filename => {
});
});
const demoJs = resolve(dest, './demo.js');
const fileList = ['demo.js', 'fineui.js', '2.0/fineui.js'];
fileList.forEach(filename => {
const sourcefile = resolve(dest, `./${filename}`);
const content = `${readFileSync(demoJs, { encoding: 'utf8' })}
//# sourceMappingURL=./demo.js.map`;
const content = `${readFileSync(sourcefile, { encoding: 'utf8' })}
//# sourceMappingURL=./${filename}.map`;
writeFileSync(demoJs, content);
writeFileSync(sourcefile, content);
})

Loading…
Cancel
Save