Closed NehaLakma02 closed 7 months ago
Please provide an actual, minimal reproduction -- screenshots (and collapsed ones, at that) show us no environment info or complete usage information. They're not very helpful in diagnosing an issue.
Happening me as well, I believe it is because "@preact/signals-react-transform"
is needed, and neither of us have it. I am currently looking into how to configure it with Vite, as I don't have babel.
Got it working by editing vite.config.ts
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
// https://vitejs.dev/config/
export default defineConfig({
plugins: [
react({
babel: {
plugins: [['module:@preact/signals-react-transform']],
},
}),
],
});
Also had to npm install --save-dev @preact/signals-react-transform
(or Yarn/Bun equivalent).
Glad to hear you got it working! Thanks for posting your fix back here.
Thanks @Foorack that was exactly what I needed! This approach to state management is awesome. Great work to the preact team 👌
I thought of introducing signals in my project, watched few videos and read the documentation. Replaced one state with signal in one the files, just to test first and it doesn't work.
configuration: vite
When I click on
view geofence
modal open but in the child modal when I trigger close modal it doesn't work.XantreGodlike andrewiggins