Skip to content

Commit 3c6e52b

Browse files
committed
- Update tsconfig.json to exclude the examples folder.
- Fix import paths to explicitly include `.js` extension where required. - Adjust test assertions to correct minor syntax issue.
1 parent ee6719d commit 3c6e52b

File tree

4 files changed

+6
-5
lines changed

4 files changed

+6
-5
lines changed

script/generateDiagram.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { createSyntaxDiagramsCode } from 'chevrotain';
22
import { writeFileSync } from 'fs';
3-
import { parser } from '../src/load/parser';
3+
import { parser } from '../src/load/parser.js';
44

55
const outputDiagram = () => {
66
const serializedGrammar = parser.getSerializedGastProductions();

test.setup.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
import { envs } from './src/common/environment';
1+
import { envs } from './src/common/environment.js';
22

33
envs.enableDebug();

test/string.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ special = "🎵 La-la-la ♪ (⌐■_■) →★←"
258258
259259
# Stress test string
260260
stress = "🏳️‍🌈 Hello\\t世界\\n☮️\\u0026\\u2764 Peace & Love ✌🏽 🌏"`;
261-
261+
262262
const result = load(input);
263263

264264
expect(result).toEqual({
@@ -268,6 +268,6 @@ stress = "🏳️‍🌈 Hello\\t世界\\n☮️\\u0026\\u2764 Peace & Love ✌
268268
escaped_mix: 'Hi 🙋‍♂️ 💻',
269269
multilang: 'Café ☕️ & Ramen 🍜 = 💖',
270270
special: '🎵 La-la-la ♪ (⌐■_■) →★←',
271-
stress: '🏳️‍🌈 Hello\t世界\n☮️&❤ Peace & Love ✌🏽 🌏'
271+
stress: '🏳️‍🌈 Hello\t世界\n☮️&❤ Peace & Love ✌🏽 🌏',
272272
});
273273
});

tsconfig.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
]
77
},
88
"exclude": [
9-
"node_modules"
9+
"node_modules",
10+
"examples"
1011
]
1112
}

0 commit comments

Comments
 (0)