You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- JavaScript components will now _automagically_ use ReactPy's internal version of ReactJS, even if the user forgot to call `import_reactjs` within `html.head(...)`. As a result, this adds a few improvements:
- Components from `component_from_npm` can now piggy-back on ReactPy's internal ReactJS export to prevent bugs caused by ReactJS version mismatches.
- Components from `component_from_file` and `component_from_string` no longer need to be compiled/built by the user (with `vite`, `webpack`, `rollup`, etc) if they only use the following imports: `react`, `react-dom`, `react-dom/client`, and `react/jsx-runtime`.
- Changes to test suite, fixtures, and tooling to allow pytest to run in parallel mode (via `hatch test --parallel`). This reduces test runtime from ~150 seconds to ~20 seconds on local machines.
- Fix bug where ReactJS components from `component_from_npm` could generate a `ReactDOM.createRoot was called on existing root` warning.
- Move `reactpy.pyscript` code into `reactpy.executors.pyscript`
"ReactPy did not detect a component binding function or a suitable 'importmap'. Using ReactPy's internal framework (Preact) to bind your JavaScript components.",
11
+
console.error(
12
+
"Unknown error occurred: 'react' is missing within this ReactPy environment! \
13
+
Your JavaScript components may not work as expected!",
0 commit comments