-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(deps): bump esbuild to latest, remove shim (#3860)
Co-authored-by: Kent C. Dodds <me+github@kentcdodds.com>
- Loading branch information
1 parent
99329de
commit cf1f2d8
Showing
5 changed files
with
122 additions
and
112 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
--- | ||
"remix": patch | ||
"@remix-run/dev": patch | ||
--- | ||
|
||
use esbuild's new automatic jsx transform | ||
|
||
there are no code changes from your end, but by using the new transform, we can prevent duplicate React imports from appearing in your build (#2987) | ||
|
||
the automatic jsx transform was introduced in React 17 and allows you to write your React code without ever needing to import React to just write jsx, if you used `useState` or other hooks, you still needed it. However up until now, esbuild didnt support this and instead recommended you to use a "shim" to add `import React from 'react'` to your files to get the same affect. This unfortantely has caused some pain points with some external libraries resulting in React being declared multiple times, but no more! (Chance said so himself, so... go tell him if it's busted) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.