Skip to content

Commit

Permalink
better file structure
Browse files Browse the repository at this point in the history
  • Loading branch information
anil-e committed Nov 24, 2023
1 parent cb5efa7 commit 4cf1697
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
12 changes: 6 additions & 6 deletions esbuild.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,19 @@ import esbuild from "esbuild";
import process from "process";
import builtins from "builtin-modules";

const banner =
`/*
const banner = `/*
THIS IS A GENERATED/BUNDLED FILE BY ESBUILD
if you want to view the source, please visit the github repository of this plugin
*/
`;

const prod = (process.argv[2] === "production");
const prod = process.argv[2] === "production";

const context = await esbuild.context({
banner: {
js: banner,
},
entryPoints: ["main.ts"],
entryPoints: ["src/main.ts"],
bundle: true,
external: [
"obsidian",
Expand All @@ -31,7 +30,8 @@ const context = await esbuild.context({
"@lezer/common",
"@lezer/highlight",
"@lezer/lr",
...builtins],
...builtins,
],
format: "cjs",
target: "es2018",
logLevel: "info",
Expand All @@ -45,4 +45,4 @@ if (prod) {
process.exit(0);
} else {
await context.watch();
}
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"scripts": {
"dev": "node esbuild.config.mjs",
"build": "tsc -noEmit -skipLibCheck && node esbuild.config.mjs production",
"version": "node version-bump.mjs && git add manifest.json versions.json"
"version": "node scripts/version-bump.mjs && git add manifest.json versions.json"
},
"keywords": [],
"author": "",
Expand Down
File renamed without changes.
File renamed without changes.

0 comments on commit 4cf1697

Please sign in to comment.