Skip to content

Commit 5bec018

Browse files
committed
Use CommonJS on the playground test, due to the limit of JSOO
1 parent 0067a89 commit 5bec018

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ $ node
262262

263263
### Testing the Playground bundle
264264

265-
Run `node playground/playground_test.js` for a quick sanity check to see if all the build artifacts are working together correctly. When releasing the playground bundle, the test will always be executed before publishing to catch regressions.
265+
Run `node playground/playground_test.cjs` for a quick sanity check to see if all the build artifacts are working together correctly. When releasing the playground bundle, the test will always be executed before publishing to catch regressions.
266266

267267
### Working on the Playground JS API
268268

@@ -272,7 +272,7 @@ Whenever you are modifying any files in the ReScript compiler, or in the `jsoo_p
272272
make playground
273273
274274
# optionally run your test / arbitrary node script to verify your changes
275-
node playground/playground_test.js
275+
node playground/playground_test.cjs
276276
```
277277

278278
### Publishing the Playground Bundle on our KeyCDN

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ playground-cmijs: artifacts
7373
# Builds the playground, runs some e2e tests and releases the playground to the
7474
# CDN (requires KEYCDN_USER and KEYCDN_PASSWORD set in the env variables)
7575
playground-release: playground playground-cmijs
76-
node playground/playground_test.js
76+
node playground/playground_test.cjs
7777
sh playground/upload_bundle.sh
7878

7979
format:

playground/playground_test.js renamed to playground/playground_test.cjs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import "./compiler.js";
2-
import "./packages/compiler-builtins/cmij.js";
3-
import "./packages/@rescript/react/cmij.js";
1+
require("./compiler.js");
2+
require("./packages/compiler-builtins/cmij.js");
3+
require("./packages/@rescript/react/cmij.js");
44

55
const compiler = rescript_compiler.make();
66

0 commit comments

Comments
 (0)