Skip to content

Commit 24bbf17

Browse files
committed
fix: change bundler to esbuild, update deps, fix security stuff
BREAKING-CHANGE: should work as before but has new bundler.
1 parent c492a42 commit 24bbf17

File tree

5 files changed

+13651
-4295
lines changed

5 files changed

+13651
-4295
lines changed

.drone.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
kind: template
2+
load: nodePackagePublishToNpm.jsonnet
3+
data:
4+
node: 21

build/build.js

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
import esbuild from 'esbuild';
2+
import clear from 'esbuild-plugin-clear';
3+
import time from 'esbuild-plugin-time';
4+
import {dirname} from 'path';
5+
import {fileURLToPath} from 'url';
6+
7+
const __dirname = dirname(fileURLToPath(import.meta.url));
8+
9+
10+
esbuild.build({
11+
entryPoints: ['./src/index.js'],
12+
bundle: true,
13+
minify: true,
14+
sourcemap: false,
15+
target: ['esnext'],
16+
format: 'esm',
17+
legalComments: 'none',
18+
outfile: './dist/parser.js',
19+
plugins: [
20+
clear('./dist'),
21+
time(),
22+
],
23+
});
24+
25+
esbuild.build({
26+
entryPoints: ['./src/simple.js'],
27+
bundle: true,
28+
minify: true,
29+
sourcemap: false,
30+
target: ['esnext'],
31+
format: 'esm',
32+
legalComments: 'none',
33+
outfile: './dist/simple.js',
34+
plugins: [
35+
time(),
36+
],
37+
});

0 commit comments

Comments
 (0)