typenative 0.0.21 → 0.1.0

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "typenative",
3
- "version": "0.0.21",
3
+ "version": "0.1.0",
4
4
  "description": "Build native applications using Typescript.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -10,41 +10,62 @@
10
10
  "scripts": {
11
11
  "build": "tsc",
12
12
  "watch": "tsc --watch",
13
+ "build:native": "node scripts/build-native.mjs",
13
14
  "test": "node ./test/test-runner test",
15
+ "features": "node scripts/features.mjs",
14
16
  "release": "npm publish",
15
- "test1": "node ./bin/index --source test/test1.spec.ts --script",
16
- "test2": "node ./bin/index --source test/test2.spec.ts --script",
17
- "test3": "node ./bin/index --source test/test3.spec.ts --script",
17
+ "test1": "node ./bin/cli.js --source test/test1.spec.ts --script",
18
+ "test2": "node ./bin/cli.js --source test/test2.spec.ts --script",
19
+ "test3": "node ./bin/cli.js --source test/test3.spec.ts --script",
18
20
  "test3_node": "tsc test/test3.spec.ts && node test/test3.spec.js && rimraf test/test3.spec.js",
19
- "test4": "node ./bin/index --source test/test4.spec.ts --script",
20
- "test5": "node ./bin/index --source test/test5.spec.ts --script",
21
- "test6": "node ./bin/index --source test/test6.spec.ts --script",
22
- "test7": "node ./bin/index --source test/test7.spec.ts --script",
23
- "test8": "node ./bin/index --source test/test8.spec.ts --script",
24
- "test9": "node ./bin/index --source test/test9.spec.ts --script",
25
- "test10": "node ./bin/index --source test/test10.spec.ts --script",
26
- "test11": "node ./bin/index --source test/test11.spec.ts --script",
27
- "test12": "node ./bin/index --source test/test12.spec.ts --script",
28
- "test13": "node ./bin/index --source test/test13.spec.ts --script",
29
- "test14": "node ./bin/index --source test/test14.spec.ts --script",
30
- "test15": "node ./bin/index --source test/test15.spec.ts --script",
31
- "test16": "node ./bin/index --source test/test16.spec.ts --script",
32
- "test17": "node ./bin/index --source test/test17.spec.ts --script",
33
- "test18": "node ./bin/index --source test/test18.spec.ts --script",
34
- "test19": "node ./bin/index --source test/test19.spec.ts --script",
35
- "test20": "node ./bin/index --source test/Test20.spec.ts --script",
36
- "test21": "node ./bin/index --source test/Test21.spec.ts --script",
37
- "test22": "node ./bin/index --source test/Test22.spec.ts --script",
38
- "test23": "node ./bin/index --source test/Test23.spec.ts --script",
39
- "test24": "node ./bin/index --source test/Test24.spec.ts --script",
40
- "test25": "node ./bin/index --source test/Test25.spec.ts --script",
41
- "test25_export": "node ./bin/index --source test/Test25-export.spec.ts --script",
42
- "test26": "node ./bin/index --source test/Test26.spec.ts --script",
43
- "test27": "node ./bin/index --source test/Test27.spec.ts --script",
44
- "test28": "node ./bin/index --source test/test28.spec.ts --script",
45
- "test29": "node ./bin/index --source test/test29.spec.ts --script",
46
- "test30": "node ./bin/index --source test/test30.spec.ts --script",
47
- "test32": "node ./bin/cli.js --source test/test31.spec.ts --script"
21
+ "test4": "node ./bin/cli.js --source test/test4.spec.ts --script",
22
+ "test5": "node ./bin/cli.js --source test/test5.spec.ts --script",
23
+ "test6": "node ./bin/cli.js --source test/test6.spec.ts --script",
24
+ "test7": "node ./bin/cli.js --source test/test7.spec.ts --script",
25
+ "test8": "node ./bin/cli.js --source test/test8.spec.ts --script",
26
+ "test9": "node ./bin/cli.js --source test/test9.spec.ts --script",
27
+ "test10": "node ./bin/cli.js --source test/test10.spec.ts --script",
28
+ "test11": "node ./bin/cli.js --source test/test11.spec.ts --script",
29
+ "test12": "node ./bin/cli.js --source test/test12.spec.ts --script",
30
+ "test13": "node ./bin/cli.js --source test/test13.spec.ts --script",
31
+ "test14": "node ./bin/cli.js --source test/test14.spec.ts --script",
32
+ "test15": "node ./bin/cli.js --source test/test15.spec.ts --script",
33
+ "test16": "node ./bin/cli.js --source test/test16.spec.ts --script",
34
+ "test17": "node ./bin/cli.js --source test/test17.spec.ts --script",
35
+ "test18": "node ./bin/cli.js --source test/test18.spec.ts --script",
36
+ "test19": "node ./bin/cli.js --source test/test19.spec.ts --script",
37
+ "test20": "node ./bin/cli.js --source test/test20.spec.ts --script",
38
+ "test21": "node ./bin/cli.js --source test/test21.spec.ts --script",
39
+ "test22": "node ./bin/cli.js --source test/test22.spec.ts --script",
40
+ "test23": "node ./bin/cli.js --source test/test23.spec.ts --script",
41
+ "test24": "node ./bin/cli.js --source test/test24.spec.ts --script",
42
+ "test25": "node ./bin/cli.js --source test/test25.spec.ts --script",
43
+ "test25_export": "node ./bin/cli.js --source test/test25-export.spec.ts --script",
44
+ "test26": "node ./bin/cli.js --source test/test26.spec.ts --script",
45
+ "test27": "node ./bin/cli.js --source test/test27.spec.ts --script",
46
+ "test28": "node ./bin/cli.js --source test/test28.spec.ts --script",
47
+ "test29": "node ./bin/cli.js --source test/test29.spec.ts --script",
48
+ "test30": "node ./bin/cli.js --source test/test30.spec.ts --script",
49
+ "test31": "node ./bin/cli.js --source test/test31.spec.ts --script",
50
+ "test32": "node ./bin/cli.js --source test/test32.spec.ts --script",
51
+ "test33": "node ./bin/cli.js --source test/test33.spec.ts --script",
52
+ "test34": "node ./bin/cli.js --source test/test34.spec.ts --script",
53
+ "test35": "node ./bin/cli.js --source test/test35.spec.ts --script",
54
+ "test36": "node ./bin/cli.js --source test/test36.spec.ts --script",
55
+ "test37": "node ./bin/cli.js --source test/test37.spec.ts --script",
56
+ "test38": "node ./bin/cli.js --source test/test38.spec.ts --script",
57
+ "test39": "node ./bin/cli.js --source test/test39.spec.ts --script",
58
+ "test40": "node ./bin/cli.js --source test/test40.spec.ts --script",
59
+ "test41": "node ./bin/cli.js --source test/test41.spec.ts --script",
60
+ "test42": "node ./bin/cli.js --source test/test42.spec.ts --script",
61
+ "test43": "node ./bin/cli.js --source test/test43.spec.ts --script",
62
+ "test44": "node ./bin/cli.js --source test/test44.spec.ts --script",
63
+ "test45": "node ./bin/cli.js --source test/test45.spec.ts --script",
64
+ "test46": "node ./bin/cli.js --source test/test46.spec.ts --script",
65
+ "test47": "node ./bin/cli.js --source test/test47.spec.ts --script",
66
+ "test48": "node ./bin/cli.js --source test/test48.spec.ts --script",
67
+ "test49": "node ./bin/cli.js --source test/test49.spec.ts --script",
68
+ "test50": "node ./bin/cli.js --source test/test50.spec.ts --script"
48
69
  },
49
70
  "repository": {
50
71
  "type": "git",
package/tsparser/main.go CHANGED
@@ -187,9 +187,9 @@ func serializeField(name string, v reflect.Value) (string, any, bool) {
187
187
  case reflect.Bool:
188
188
  return lowerFirst(name), v.Bool(), true
189
189
  case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64:
190
- // Operator fields hold token kinds; emit the kind name (matches the
190
+ // Operator/Token fields hold token kinds; emit the kind name (matches the
191
191
  // Node producer, which converts ts.SyntaxKind numbers to names)
192
- if name == "operator" { // prelude lowercased the field name
192
+ if name == "operator" || name == "token" { // prelude lowercased the field name
193
193
  kind := ast.Kind(v.Int())
194
194
  return lowerFirst(name), strings.TrimPrefix(kind.String(), "Kind"), true
195
195
  }
@@ -1,4 +1,4 @@
1
1
  [diffend] Oversized file quarantined before diffing.
2
2
  name: package/tsparser/tsparser.exe
3
- size: 37218816 bytes
4
- sha256: 109079917c83dd2abf4b8864df2d7cbaa02f0686c092685e9698557e9be4d10c
3
+ size: 37234176 bytes
4
+ sha256: ce98ee3136dc50c07e1d3c12ace366c7f7180982c7cc14615ac614ab34fc63ae