Skip to content

Commit 0123d92

Browse files
committed
Grammar
1 parent 3f33c8a commit 0123d92

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

content/posts/2023-11-14_Is_NodeNext_Right_For_Libraries_That_Dont_Target_NodeJS.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ I think that if you transpile TS code with `NodeNext`, that will be compatible w
3232

3333
I _mostly_ agree with Matt, and his advice earlier in the thread more or less matches what I published in TypeScript’s [Choosing Compiler Options](https://www.typescriptlang.org/docs/handbook/modules/guides/choosing-compiler-options.html#im-writing-a-library) guide for modules.
3434

35-
It’s worth unpacking some of the nuances here. Something important about Tim’s position, and about how `tsc` works, is lost to the Twitter shorthand in Matt’s characterization above. `moduleResolution` doesn’t affect `tsc`’s emit, so producing two different outputs toggling that option alone would do nothing for consumers. But as Matt and Tim both know, it’s not possible to toggle _just_ `moduleResolution` between `bundler` and `nodenext`, because each of these enforce a corresponding `module` option, which _does_ affect emit:
35+
It’s worth unpacking some of the nuances here. Something important about Tim’s position, and about how `tsc` works, is lost to the Twitter shorthand in Matt’s characterization above. `moduleResolution` doesn’t affect `tsc`’s emit, so producing two different outputs toggling that option alone would do nothing for consumers. But as Matt and Tim both know, it’s not possible to toggle _just_ `moduleResolution` between `bundler` and `nodenext`, because each of these enforces a corresponding `module` option, which _does_ affect emit:
3636

3737
- `moduleResolution: bundler` requires `module: esnext`
3838
- `moduleResolution: nodenext` requires `module: nodenext`

0 commit comments

Comments
 (0)