Skip to content

Comments

Upgrade react 19#100

Merged
SilasBerger merged 26 commits intomainfrom
upgrade-react-19
May 7, 2025
Merged

Upgrade react 19#100
SilasBerger merged 26 commits intomainfrom
upgrade-react-19

Conversation

@lebalz
Copy link
Contributor

@lebalz lebalz commented Jan 17, 2025

reopens #81 (which was merged/reverted by accident)

  • use React.ReactNode instead of JSX.Element
  • updare various packages
  • ensure useRef is initialized with a value

Still blocked by: excalidraw/excalidraw#8923
Fixed Excalidraw import issues through configuration of fallbacks:

// docusaurus.config.ts#webpack
...
plugins: [
() => {
      return {
          name: 'excalidraw-config',
          configureWebpack(config, isServer, {currentBundler}) {
            return {
              module: {
                rules: [
                  {
                    test: /\.excalidraw$/,
                    type: 'json',
                  },
                  {
                    test: /\.excalidrawlib$/,
                    type: 'json',
                  }
                ],
              },
              resolve: {
                fallback: {
                  'roughjs/bin/math': path.resolve(__dirname, './node_modules/roughjs/bin/math.js'),
                  'roughjs/bin/rough': path.resolve(__dirname, './node_modules/roughjs/bin/rough.js'),
                  'roughjs/bin/generator': path.resolve(__dirname, './node_modules/roughjs/bin/generator.js')
                }
              },
              plugins: [
                new currentBundler.instance.DefinePlugin({
                  'process.env.IS_PREACT': JSON.stringify('false')
                }),
              ]
            }
          }
      }
    }
]

- use React.ReactNode instead of JSX.Element
- updare various packages
- ensure useRef is initialized with a value

(cherry picked from commit 1b4c4d5)
(cherry picked from commit 978b218)
(cherry picked from commit c109b66)
(cherry picked from commit ee170c7)
(cherry picked from commit 729a03b)
(cherry picked from commit 284b330)
@lebalz lebalz added the blocked label Jan 17, 2025
@netlify
Copy link

netlify bot commented Jan 17, 2025

Deploy Preview for teaching-dev ready!

Name Link
🔨 Latest commit cd0311b
🔍 Latest deploy log https://app.netlify.com/sites/teaching-dev/deploys/68175abd24858900081e94fd
😎 Deploy Preview https://deploy-preview-100--teaching-dev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@lebalz lebalz removed the blocked label May 1, 2025
@SilasBerger
Copy link
Contributor

Tested in my own deployment, works without issues.

@SilasBerger SilasBerger merged commit a0c25a9 into main May 7, 2025
5 checks passed
@SilasBerger SilasBerger deleted the upgrade-react-19 branch May 7, 2025 08:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants