This repository has been archived by the owner on Apr 21, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "[beta] upgrade sandpack and refactor sandpack.css (#4843)" (#…
…4959) This reverts commit 537e0a3.
- Loading branch information
Showing
15 changed files
with
397 additions
and
548 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
37 changes: 37 additions & 0 deletions
37
beta/patches/@codesandbox+sandpack-react+0.19.8-experimental.4.patch
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,37 @@ | ||
diff --git a/node_modules/@codesandbox/sandpack-react/dist/esm/index.js b/node_modules/@codesandbox/sandpack-react/dist/esm/index.js | ||
index ced9bd3..7e5e366 100644 | ||
--- a/node_modules/@codesandbox/sandpack-react/dist/esm/index.js | ||
+++ b/node_modules/@codesandbox/sandpack-react/dist/esm/index.js | ||
@@ -566,17 +566,16 @@ var REACT_TEMPLATE = { | ||
}, | ||
"/index.js": { | ||
code: `import React, { StrictMode } from "react"; | ||
-import ReactDOM from "react-dom"; | ||
+import { createRoot } from "react-dom/client"; | ||
import "./styles.css"; | ||
|
||
import App from "./App"; | ||
|
||
-const rootElement = document.getElementById("root"); | ||
-ReactDOM.render( | ||
+const root = createRoot(document.getElementById("root")); | ||
+root.render( | ||
<StrictMode> | ||
<App /> | ||
- </StrictMode>, | ||
- rootElement | ||
+ </StrictMode> | ||
);` | ||
}, | ||
"/styles.css": { | ||
@@ -611,8 +610,8 @@ h1 { | ||
} | ||
}, | ||
dependencies: { | ||
- react: "^17.0.0", | ||
- "react-dom": "^17.0.0", | ||
+ react: "^18.0.0", | ||
+ "react-dom": "^18.0.0", | ||
"react-scripts": "^4.0.0" | ||
}, | ||
entry: "/index.js", |
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 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 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 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 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.