mirror of
https://github.com/anyproto/anytype-ts.git
synced 2025-06-08 05:57:02 +09:00
add export.js to exported html, fix prism.css
This commit is contained in:
parent
db0882ba88
commit
6e35b78137
5 changed files with 24 additions and 0 deletions
11
electron.js
11
electron.js
|
@ -896,6 +896,17 @@ function savePage (name) {
|
|||
};
|
||||
|
||||
content = content.replace(/<script[^>]+><\/script>/g, '');
|
||||
|
||||
try {
|
||||
Util.log('info', app.getAppPath());
|
||||
fs.copyFileSync(app.getAppPath() + '/dist/js/export.js', path.join(filesPath, 'export.js'));
|
||||
|
||||
content = content.replace('<!-- %REPLACE% -->', `
|
||||
<script src="./${fn}/export.js" type="text/javascript"></script>
|
||||
`);
|
||||
} catch (e) {
|
||||
Util.log('info', e);
|
||||
};
|
||||
|
||||
fs.writeFileSync(exportName, content);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue