mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-08-09 17:52:32 +08:00
refactor(server): fix script dir for libraries
This commit is contained in:
parent
ac79ae29f2
commit
ae2eb9f4bb
@ -33,7 +33,10 @@ async function register(app: express.Application) {
|
||||
proxyReqPathResolver: (req) => {
|
||||
let url = req.url;
|
||||
url = url.replace(/^\/src/, "");
|
||||
url = `/${assetPath}/app/src${url}`;
|
||||
if (!url.startsWith("/@")) {
|
||||
url = "/src" + url;
|
||||
}
|
||||
url = `/${assetPath}/app${url}`;
|
||||
url = url.replace(/.js$/, ".ts");
|
||||
console.log(`${req.url} => ${publicUrl}${url}`);
|
||||
return url;
|
||||
|
Loading…
x
Reference in New Issue
Block a user