Releases: pmndrs/react-ogl
v0.14.2
What's Changed
- fix: safely import legacy act for Next by @matiasperz in #82
Full Changelog: v0.14.1...v0.14.2
v0.14.1
What's Changed
- fix: safely import legacy act for Next by @matiasperz in #80
New Contributors
- @matiasperz made their first contribution in #80
Full Changelog: v0.14.0...v0.14.1
v0.14.0
What's Changed
- feat: update Zustand to use latest API by @matiasngf in #79
New Contributors
- @matiasngf made their first contribution in #79
Full Changelog: v0.13.0...v0.14.0
v0.13.0
What's Changed
- refactor(types)!: support for OGL v1 by @CodyJasonBennett in #78
Full Changelog: v0.12.0...v0.13.0
v0.12.0
What's Changed
- refactor(types)!: upgrade Zustand to v4 by @CodyJasonBennett in #75
Full Changelog: v0.11.0...v0.12.0
v0.11.0
What's Changed
- feat(Canvas): bridge cross-container context by @CodyJasonBennett in #74
This release implements a context bridge within Canvas
, enabling react-ogl children to consume context between renderers (e.g. react-dom
or react-native
), and removing the need for manually bridging context.
import * as React from 'react'
import * as ReactDOM from 'react-dom/client'
import { Canvas } from 'react-ogl'
const DOMContext = React.createContext()
function Component() {
// "Hello from react-dom"
console.log(React.useContext(DOMContext))
}
ReactDOM.createRoot(document.getElementById('root')).render(
<DOMContext.Provider value="Hello from react-dom">
<Canvas>
<Component />
</Canvas>
</DOMContext.Provider>,
)
Full Changelog: v0.10.1...v0.11.0
v0.10.1
What's Changed
- experiment: add module field for bundlephobia by @CodyJasonBennett in #73
No changes in this release. Working around a Bundlephobia issue to get bundle size metrics working again.
Full Changelog: v0.10.0...v0.10.1
v0.10.0
What's Changed
- feat: container effects, recursive dispose, portal state by @CodyJasonBennett in #72
This release includes some upstream fixes for suspense and concurrency.
Additionally, portals can now create state enclaves to isolate scenes, cameras, etc. from the root store. This is particularly useful for postprocessing and complex effects.
function Component {
// scene & camera are inherited from portal parameters
const { scene, camera, ... } = useOGL()
}
const scene = new OGL.Transform()
const camera = new OGL.Camera()
<transform>
{createPortal(<Component />, scene, { camera })
</transform>
Full Changelog: v0.9.2...v0.10.0
v0.9.2
v0.9.1
What's Changed
- fix(useLoader): pass src to textureloader by @CodyJasonBennett in #70
Full Changelog: v0.9.0...v0.9.1