Skip to content

Commit 0c3d1fa

Browse files
committed
New point release
Type reference was not ok and a separate tsconfig.json has been added for the unit tests. Signed-off-by: Mike Lischke <[email protected]>
1 parent b8e2ce5 commit 0c3d1fa

File tree

6 files changed

+39
-9
lines changed

6 files changed

+39
-9
lines changed

.eslintrc.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@
2323
"parser": "@typescript-eslint/parser",
2424
"parserOptions": {
2525
"project": [
26-
"tsconfig.json"
26+
"tsconfig.json",
27+
"tests/tsconfig.json"
2728
],
2829
"sourceType": "module",
2930
"implicitStrict": true,

.npmignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
cli/
55
tests/
66
coverage/
7-
src/**/*.js
87
dist/*.map
8+
src/
99

1010
jest.config.ts
1111
.eslintignore

package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"name": "antlr4ng",
3-
"version": "2.0.0",
3+
"version": "2.0.1",
44
"type": "module",
55
"description": "Alternative JavaScript/TypeScript runtime for ANTLR4",
66
"main": "dist/antlr4.mjs",
7-
"types": "src/index.d.ts",
7+
"types": "dist/index.d.ts",
88
"repository": "https://github.com/mike-lischke/antlr4ng",
99
"keywords": [
1010
"lexer",
@@ -51,7 +51,7 @@
5151
"process profile tick file": " node --prof-process isolate-0x130008000-75033-v8.log > processed.txt"
5252
},
5353
"exports": {
54-
"types": "./src/index.ts",
54+
"types": "./dist/index.d.ts",
5555
"default": "./dist/antlr4.mjs"
5656
}
5757
}

tests/benchmarks/run-benchmarks.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
/* eslint-disable no-underscore-dangle */
77

8-
import fs from "fs";
8+
import * as fs from "fs";
99
import path from "path";
1010
import assert from "assert";
1111
import { fileURLToPath } from "url";

tests/tsconfig.json

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
{
2+
"compilerOptions": {
3+
"declaration": true,
4+
"module": "Node16",
5+
"target": "ESNext",
6+
"moduleResolution": "Node16",
7+
"noEmit": true,
8+
"removeComments": false,
9+
"noImplicitAny": true,
10+
"noImplicitOverride": false,
11+
"sourceMap": true,
12+
"inlineSources": true,
13+
"isolatedModules": false,
14+
"allowSyntheticDefaultImports": true,
15+
"strictNullChecks": true,
16+
},
17+
"include": [
18+
"**/*.ts",
19+
],
20+
"exclude": [
21+
"node_modules",
22+
"dist/**/*",
23+
"src/**/*"
24+
]
25+
}

tsconfig.json

+7-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,10 @@
55
"moduleResolution": "Node16",
66
"sourceMap": true,
77
"esModuleInterop": true,
8-
"noEmit": true,
8+
"noEmit": false,
9+
"declaration": true,
10+
"emitDeclarationOnly": true,
11+
"outDir": "dist",
912
"lib": [
1013
"ESNext",
1114
"DOM"
@@ -21,10 +24,11 @@
2124
},
2225
"include": [
2326
"src/**/*.ts",
24-
"tests/**/*.ts"
2527
],
2628
"exclude": [
27-
"node_modules"
29+
"dist",
30+
"node_modules",
31+
"tests"
2832
],
2933
"compileOnSave": true,
3034
"ts-node": {

0 commit comments

Comments
 (0)