-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwasmc.js
More file actions
43 lines (38 loc) · 816 Bytes
/
Copy pathwasmc.js
File metadata and controls
43 lines (38 loc) · 816 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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
const package = require("./package.json")
const outdir = debug ? builddir : "dist"
const m = {
name: "markdown",
out: outdir + "/markdown.js",
jsentry: "src/md.js",
sources: [
"src/wlib.c",
"src/wbuf.c",
"src/md.c",
"src/md4c.c",
"src/fmt_html.c",
// "src/fmt_json.c",
],
cflags: debug ? ["-DDEBUG=1"] : [],
constants: {
VERSION: package.version,
},
}
if (!debug) {
// generic js module
module({...m})
// node cjs module
// module({ ...m,
// name: "markdown-node",
// out: outdir + "/markdown.node.js",
// target: "node",
// embed: true,
// })
}
// // node es module
// module({ ...m,
// name: "markdown-es",
// out: outdir + "/markdown.es.js",
// format: "es",
// target: "node",
// embed: true,
// })