mirror of
https://github.com/plankanban/planka.git
synced 2025-07-18 12:49:43 +02:00
fix: Fix paths in css files when building on windows
This commit is contained in:
parent
f9d191ecc8
commit
9c241acff8
1 changed files with 3 additions and 1 deletions
|
@ -22,7 +22,9 @@ const replaceBaseUrl = (compiler) => {
|
|||
if (info.content.indexOf(BASE_URL_PLACEHOLDER) >= 0) {
|
||||
if (/\.css$/.exec(info.targetPath)) {
|
||||
// For CSS 'url(...)' import we can use relative import
|
||||
const relPath = path.relative(path.dirname(info.targetPath), info.outputPath);
|
||||
const relPath = path
|
||||
.relative(path.dirname(info.targetPath), info.outputPath)
|
||||
.replace(/\\/g, '/');
|
||||
replaceInFile(info.targetPath, BASE_URL_PLACEHOLDER, `${relPath}/`);
|
||||
} else if (/\.js$/.exec(info.targetPath)) {
|
||||
// For JS 'import ... from "some-asset"' we can get the variable injected in the window object
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue