mirror of
https://github.com/chinchang/web-maker.git
synced 2025-07-26 08:11:17 +02:00
mv3 code changes
This commit is contained in:
@@ -377,7 +377,7 @@ export function getCompleteHtml(html, css, js, item, isForExport) {
|
||||
contents +=
|
||||
'<script src="' +
|
||||
(chrome.extension
|
||||
? chrome.extension.getURL('lib/screenlog.js')
|
||||
? chrome.runtime.getURL('lib/screenlog.js')
|
||||
: `${location.origin}${
|
||||
window.DEBUG ? '' : BASE_PATH
|
||||
}/lib/screenlog.js`) +
|
||||
@@ -388,7 +388,7 @@ export function getCompleteHtml(html, css, js, item, isForExport) {
|
||||
contents +=
|
||||
'<script src="' +
|
||||
(chrome.extension
|
||||
? chrome.extension.getURL('lib/transpilers/babel-polyfill.min.js')
|
||||
? chrome.runtime.getURL('lib/transpilers/babel-polyfill.min.js')
|
||||
: `${location.origin}${BASE_PATH}/lib/transpilers/babel-polyfill.min.js`) +
|
||||
'"></script>';
|
||||
}
|
||||
@@ -495,7 +495,7 @@ export function prettify({ file, content, type }) {
|
||||
}
|
||||
const worker = new Worker(
|
||||
chrome.extension
|
||||
? chrome.extension.getURL('lib/prettier-worker.js')
|
||||
? chrome.runtime.getURL('lib/prettier-worker.js')
|
||||
: `${BASE_PATH !== '/' ? BASE_PATH : ''}/lib/prettier-worker.js`
|
||||
);
|
||||
worker.postMessage({ content, type });
|
||||
|
Reference in New Issue
Block a user