@swc/core 1.2.99 → 1.2.103

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,5 @@
1
+ #!/bin/sh
2
+ . "$(dirname "$0")/_/husky.sh"
3
+
4
+ # TODO: lint-staged
5
+ # cargo fmt --all -- --check
@@ -0,0 +1,5 @@
1
+ #!/bin/sh
2
+ . "$(dirname "$0")/_/husky.sh"
3
+
4
+ # yarn run cspell "**/src/**/*.rs"
5
+ cargo fmt --all -- --check
package/cspell.json ADDED
@@ -0,0 +1,128 @@
1
+ {
2
+ "version": "0.2",
3
+ "language": "en",
4
+ "allowCompoundWords": true,
5
+ "words": [
6
+ "aarch",
7
+ "ahash",
8
+ "anonymized",
9
+ "ANONYMIZED",
10
+ "Ansi",
11
+ "armv",
12
+ "arrayvec",
13
+ "ascii",
14
+ "babelify",
15
+ "Babelify",
16
+ "bools",
17
+ "bpos",
18
+ "BUILTINS",
19
+ "canonicalization",
20
+ "canonicalize",
21
+ "chpos",
22
+ "cmpeq",
23
+ "cmplt",
24
+ "cmts",
25
+ "cname",
26
+ "combinator",
27
+ "Combinator",
28
+ "cond",
29
+ "Cond",
30
+ "constness",
31
+ "corejs",
32
+ "ctxt",
33
+ "ctxts",
34
+ "Cutomizing",
35
+ "dedup",
36
+ "dejavu",
37
+ "delim",
38
+ "Delim",
39
+ "deno",
40
+ "Deno",
41
+ "deps",
42
+ "Deque",
43
+ "Deser",
44
+ "dont",
45
+ "DWORD",
46
+ "ecmascript",
47
+ "eddyb",
48
+ "elems",
49
+ "esbuild",
50
+ "esms",
51
+ "eval",
52
+ "Eval",
53
+ "exponentation",
54
+ "fargs",
55
+ "finalizer",
56
+ "fnames",
57
+ "gnueabihf",
58
+ "hasher",
59
+ "idents",
60
+ "iife",
61
+ "impls",
62
+ "indexmap",
63
+ "instanceof",
64
+ "interner",
65
+ "intrinsics",
66
+ "ints",
67
+ "jsonify",
68
+ "jsxs",
69
+ "jszip",
70
+ "kaios",
71
+ "keyof",
72
+ "linebpos",
73
+ "linechpos",
74
+ "loadu",
75
+ "LPCSTR",
76
+ "LPSECURITY",
77
+ "mbcs",
78
+ "mimalloc",
79
+ "minifier",
80
+ "miri",
81
+ "mkdir",
82
+ "msvc",
83
+ "napi",
84
+ "nncs",
85
+ "noinline",
86
+ "NOINLINE",
87
+ "paren",
88
+ "Paren",
89
+ "pmutil",
90
+ "pointee",
91
+ "prec",
92
+ "PREC",
93
+ "proto",
94
+ "punct",
95
+ "putc",
96
+ "qself",
97
+ "regs",
98
+ "repr",
99
+ "rfind",
100
+ "rpos",
101
+ "rposition",
102
+ "rsplit",
103
+ "rustc",
104
+ "sabi",
105
+ "seqs",
106
+ "sess",
107
+ "skippable",
108
+ "smallvec",
109
+ "spanx",
110
+ "stmts",
111
+ "succ",
112
+ "sugg",
113
+ "swcify",
114
+ "swcpack",
115
+ "swcrc",
116
+ "systemjs",
117
+ "termcolor",
118
+ "typeofs",
119
+ "uncons",
120
+ "Unexported",
121
+ "Unexporter",
122
+ "unimpl",
123
+ "untrusted"
124
+ ],
125
+ "flagWords": [
126
+ "actally"
127
+ ]
128
+ }
package/deny.toml CHANGED
@@ -50,6 +50,7 @@ notice = "warn"
50
50
  ignore = [
51
51
  #"RUSTSEC-0000-0000",
52
52
  "RUSTSEC-2020-0071",
53
+ "RUSTSEC-2020-0159",
53
54
  ]
54
55
  # Threshold for security vulnerabilities, any vulnerability with a CVSS score
55
56
  # lower than the range specified will be ignored. Note that ignored advisories
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@swc/core",
3
- "version": "1.2.99",
3
+ "version": "1.2.103",
4
4
  "description": "Super-fast alternative for babel",
5
5
  "homepage": "https://swc.rs",
6
6
  "main": "./index.js",
@@ -8,7 +8,7 @@
8
8
  "license": "Apache-2.0 AND MIT",
9
9
  "keywords": [
10
10
  "swc",
11
- "spack",
11
+ "swcpack",
12
12
  "babel",
13
13
  "typescript",
14
14
  "rust",
@@ -36,6 +36,7 @@
36
36
  "armv7-unknown-linux-gnueabihf",
37
37
  "aarch64-apple-darwin",
38
38
  "aarch64-linux-android",
39
+ "x86_64-unknown-freebsd",
39
40
  "aarch64-unknown-linux-musl",
40
41
  "aarch64-pc-windows-msvc"
41
42
  ]
@@ -48,8 +49,23 @@
48
49
  "dependencies": {
49
50
  "@node-rs/helper": "^1.0.0"
50
51
  },
52
+ "optionalDependencies": {
53
+ "@swc/core-win32-x64-msvc": "1.2.103",
54
+ "@swc/core-darwin-x64": "1.2.103",
55
+ "@swc/core-linux-x64-gnu": "1.2.103",
56
+ "@swc/core-linux-x64-musl": "1.2.103",
57
+ "@swc/core-win32-ia32-msvc": "1.2.103",
58
+ "@swc/core-linux-arm64-gnu": "1.2.103",
59
+ "@swc/core-linux-arm-gnueabihf": "1.2.103",
60
+ "@swc/core-darwin-arm64": "1.2.103",
61
+ "@swc/core-android-arm64": "1.2.103",
62
+ "@swc/core-freebsd-x64": "1.2.103",
63
+ "@swc/core-linux-arm64-musl": "1.2.103",
64
+ "@swc/core-win32-arm64-msvc": "1.2.103"
65
+ },
51
66
  "types": "./index.d.ts",
52
67
  "scripts": {
68
+ "prepare": "husky install",
53
69
  "artifacts": "napi artifacts --dist scripts/npm",
54
70
  "prepublishOnly": "tsc -d && napi prepublish -p scripts/npm --tagstyle npm",
55
71
  "build": "tsc -d && napi build --platform --release --cargo-name node --cargo-flags=\"-p node\"",
@@ -75,6 +91,8 @@
75
91
  "browserslist": "^4.16.6",
76
92
  "core-js": "^2.6.11",
77
93
  "cross-env": "^7.0.3",
94
+ "cspell": "^5.12.3",
95
+ "husky": "^7.0.2",
78
96
  "jest": "^27.0.1",
79
97
  "lodash": "^4.17.21",
80
98
  "progress": "^2.0.3",
@@ -90,18 +108,5 @@
90
108
  "funding": {
91
109
  "type": "opencollective",
92
110
  "url": "https://opencollective.com/swc"
93
- },
94
- "optionalDependencies": {
95
- "@swc/core-win32-x64-msvc": "1.2.99",
96
- "@swc/core-darwin-x64": "1.2.99",
97
- "@swc/core-linux-x64-gnu": "1.2.99",
98
- "@swc/core-linux-x64-musl": "1.2.99",
99
- "@swc/core-win32-ia32-msvc": "1.2.99",
100
- "@swc/core-linux-arm64-gnu": "1.2.99",
101
- "@swc/core-linux-arm-gnueabihf": "1.2.99",
102
- "@swc/core-darwin-arm64": "1.2.99",
103
- "@swc/core-android-arm64": "1.2.99",
104
- "@swc/core-linux-arm64-musl": "1.2.99",
105
- "@swc/core-win32-arm64-msvc": "1.2.99"
106
111
  }
107
112
  }
package/types.d.ts CHANGED
@@ -333,7 +333,7 @@ export interface JscConfig {
333
333
  };
334
334
  minify?: JsMinifyOptions;
335
335
  }
336
- export declare type JscTarget = "es3" | "es5" | "es2015" | "es2016" | "es2017" | "es2018" | "es2019" | "es2020" | "es2021";
336
+ export declare type JscTarget = "es3" | "es5" | "es2015" | "es2016" | "es2017" | "es2018" | "es2019" | "es2020" | "es2021" | "es2022";
337
337
  export declare type ParserConfig = TsParserConfig | EsParserConfig;
338
338
  export interface TsParserConfig {
339
339
  syntax: "typescript";