-
Notifications
You must be signed in to change notification settings - Fork 340
Expand file tree
/
Copy pathMakefile
More file actions
28 lines (19 loc) · 665 Bytes
/
Copy pathMakefile
File metadata and controls
28 lines (19 loc) · 665 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
SRC_DEPS = src/index.tsx src/third-party/qrcodegen/index.ts
CFG_DEPS = pnpm-lock.yaml package.json tsup.config.ts tsconfig.json
EXAMPLE_DEPS = examples/*.tsx
.PHONY: all clean
all: lib/index.js lib/index.d.ts lib/index.d.mts lib/index.js examples/iife/demo.js
lib:
mkdir -p lib
lib/index.d.ts: lib $(SRC_DEPS) $(CFG_DEPS)
pnpm run build:code
lib/index.d.mts: lib $(SRC_DEPS) $(CFG_DEPS)
pnpm run build:code
lib/esm/index.js: lib $(SRC_DEPS) $(CFG_DEPS)
pnpm run build:code
lib/index.js: lib $(SRC_DEPS) $(CFG_DEPS)
pnpm run build:code
examples/iife/demo.js: lib/esm/index.js ${EXAMPLE_DEPS}
pnpm run build:examples
clean:
git clean -fX lib examples