@react-three/postprocessing 2.14.6 → 2.14.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +5 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +5 -0
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -354,6 +354,11 @@ const Glitch = React.forwardRef(function Glitch2({ active = true, ...props }, re
|
|
|
354
354
|
effect.mode = active ? props.mode || postprocessing.GlitchMode.SPORADIC : postprocessing.GlitchMode.DISABLED;
|
|
355
355
|
invalidate();
|
|
356
356
|
}, [active, effect, invalidate, props.mode]);
|
|
357
|
+
React.useEffect(() => {
|
|
358
|
+
return () => {
|
|
359
|
+
effect.dispose();
|
|
360
|
+
};
|
|
361
|
+
}, [effect]);
|
|
357
362
|
return /* @__PURE__ */ jsxRuntime.jsx("primitive", { ref, object: effect, dispose: null });
|
|
358
363
|
});
|
|
359
364
|
const GodRays = React.forwardRef(function GodRays2(props, ref) {
|