/* eslint-env node */
const fs = require('fs');
fs.readFile('editor/svg-editor-es.html', 'utf8', (err, data) => {
if (err) {
console.log('Error reading `svg-editor-es.html` file', err);
return;
}
data = data
.replace(
'',
`
`
).replace(
'',
''
).replace(
'',
''
).replace(
'',
''
);
fs.writeFile('editor/svg-editor.html', data, (err) => {
if (err) {
console.log('Error writing file', err);
return;
}
console.log('Completed file rewriting!');
});
});
fs.readFile('editor/extensions/imagelib/index-es.html', 'utf8', (err, data) => {
if (err) {
console.log('Error reading `imagelib/index-es.html` file', err);
return;
}
data = data
.replace(
'',
`
`
).replace(
'',
''
);
fs.writeFile('editor/extensions/imagelib/index.html', data, (err) => {
if (err) {
console.log('Error writing file', err);
return;
}
console.log('Completed file rewriting!');
});
});