From e0ebee5aa9b3646de722f139f1d8d15591df538e Mon Sep 17 00:00:00 2001
From: Jacky Zhao <j.zhao2k19@gmail.com>
Date: Sun, 02 Jul 2023 20:08:29 +0000
Subject: [PATCH] various polish
---
quartz/bootstrap-cli.mjs | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/quartz/bootstrap-cli.mjs b/quartz/bootstrap-cli.mjs
index e6bb3f0..3f71b17 100755
--- a/quartz/bootstrap-cli.mjs
+++ b/quartz/bootstrap-cli.mjs
@@ -64,7 +64,7 @@
packages: "external",
plugins: [
sassPlugin({
- type: 'css-text'
+ type: 'css-text',
}),
{
name: 'inline-script-loader',
@@ -75,12 +75,14 @@
text = text.replace('export default', '')
text = text.replace('export', '')
+ const sourcefile = path.relative(path.resolve('.'), args.path)
+ const resolveDir = path.dirname(sourcefile)
const transpiled = await esbuild.build({
stdin: {
contents: text,
loader: 'ts',
- resolveDir: '.',
- sourcefile: path.relative(path.resolve('.'), args.path),
+ resolveDir,
+ sourcefile,
},
write: false,
bundle: true,
--
Gitblit v1.10.0