Skip to content

Commit

Permalink
squash!
Browse files Browse the repository at this point in the history
  • Loading branch information
NikolaRHristov committed Sep 22, 2023
1 parent eb40ad4 commit f2a824d
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 40 deletions.
11 changes: 2 additions & 9 deletions Configuration/ESBuild.d.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
declare const _default: {
format: "esm";
minify: true;
outdir: string;
bundle: true;
platform: "browser";
target: string[];
plugins: import("esbuild").Plugin[];
};
import type { BuildOptions as Type } from "esbuild";
declare const _default: Type;
export default _default;
56 changes: 28 additions & 28 deletions Configuration/ESBuild.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,32 @@ import { copy as Copy } from "esbuild-plugin-copy";
import { rm as Remove } from "fs/promises";
const outDir = "Target";
export default {
format: "esm",
minify: true,
outdir: outDir,
bundle: true,
platform: "browser",
target: ["edge104", "esnext"],
plugins: [
{
name: "Target",
setup: (Build) =>
Build.onStart(async () => {
try {
await Remove(outDir, {
recursive: true,
});
} catch (_Error) {}
}),
},
Copy({
resolveFrom: "out",
assets: [
{
from: "./Source/styles/*.css",
to: "./styles/",
},
],
}),
],
format: "esm",
minify: true,
outdir: outDir,
bundle: true,
platform: "browser",
target: ["edge104", "esnext"],
plugins: [
{
name: "Target",
setup: (Build) => Build.onStart(async () => {
try {
await Remove(outDir, {
recursive: true,
});
}
catch (_Error) { }
}),
},
Copy({
resolveFrom: "out",
assets: [
{
from: "./Source/styles/*.css",
to: "./styles/",
},
],
}),
],
};
2 changes: 1 addition & 1 deletion Target/Script/Fa.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/// <reference types="node" resolution-mode="require"/>
/// <reference types="node" />
declare global {
interface Window {
interval: NodeJS.Timer;
Expand Down
2 changes: 1 addition & 1 deletion Target/Script/Ta.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/// <reference types="node" resolution-mode="require"/>
/// <reference types="node" />
declare global {
interface Window {
interval: NodeJS.Timer;
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
}
]
},
"extends": "typescript-esbuild/Target/Configuration/TypeScript",
"extends": "typescript-esbuild/Target/Notation/TypeScript",
"include": ["Source"]
}

0 comments on commit f2a824d

Please sign in to comment.