Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependency react-three-fiber to v6 #250

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

renovate[bot]
Copy link

@renovate renovate bot commented May 9, 2021

WhiteSource Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
react-three-fiber ^4.0.23 -> ^6.0.0 age adoption passing confidence

Release Notes

pmndrs/react-three-fiber

v5.3.22

Compare Source

v5.3.21

Compare Source

v5.3.20

Compare Source

v5.3.19

Compare Source

v5.3.18

Compare Source

v5.3.17

Compare Source

v5.3.16

Compare Source

v5.3.15

Compare Source

v5.3.14

Compare Source

v5.3.13

Compare Source

v5.3.12

Compare Source

v5.3.11

Compare Source

v5.3.10

Compare Source

v5.3.9

Compare Source

v5.3.8

Compare Source

v5.3.7

Compare Source

v5.3.6

Compare Source

v5.3.5

Compare Source

v5.3.4

Compare Source

v5.3.3

Compare Source

v5.3.1

Compare Source

v5.3.0

Compare Source

v5.2.1

Compare Source

v5.2.0

Compare Source

v5.1.9

Compare Source

v5.1.8

Compare Source

v5.1.7

Compare Source

v5.1.6

Compare Source

v5.1.5

Compare Source

v5.1.4

Compare Source

v5.1.3

Compare Source

v5.1.2

Compare Source

v5.1.1

Compare Source

v5.1.0

Compare Source

v5.0.6

Compare Source

v5.0.5

Compare Source

v5.0.4

Compare Source

v5.0.3

Compare Source

v5.0.2

Compare Source

v5.0.1

Compare Source

v5.0.0

Compare Source

  • Rewrite reconciler, optimize hot paths
  • Inline react-reconciler (again, faster hot paths) via closure-compiler
  • Remove bloat (<Dom />, { __$ } = useLoader, sRGB
  • Color Management by default
  • Webgl2 by default
  • Auto-attach geometries and materials
<mesh>
  <planeBufferGeometry />
  <meshBasicMaterial />
</mesh>

Current viewport is responsive to screen resize, that makes no sense because the viewport is reliant on the camera position. If the camera changes/moves, the last viewport is obsolete.

viewport.width/height/etc will still work as always, but calling it as a function gives you recalculated, fresh values.

const { viewport } = useThree()
const { width, height, factor, distance } = viewport(optionalTarget)
const ref = useResource()
  • Xhr and error-boundary support for useLoader

Crashes in loaders were previously swallowed, these will now throw so that you can catch then properly with error-boundaries. You also can tap into the loading process.

useLoader(
  Loader,
  url,
  extensions, // optional
  xhr => console.log((xhr.loaded / xhr.total * 100) + '% loaded'), // optional
)
  • Primitives do not dispose

Primitives are objects that are created imperatively, they should not be freed or disposed of by r3f.

Previously:

return <primitive object={scene} dispose={null} />

V5:

return <primitive object={scene} />

In the unlikely case that you do want to dispose a primitive (i would be OK with not documenting that at all, primitives should normally not be touched by r3f):

return <primitive object={scene} dispose={undefined} />

R3f uses use-asset instead of react-promise-suspense, which has better cache busting strategies and preload support.

import { useLoader } from "react-three-fiber"

useLoader.preload(GLTFLoader, url)

v4.2.21

Compare Source

v4.2.20

Compare Source

v4.2.19

Compare Source

v4.2.18

Compare Source

v4.2.17

Compare Source

v4.2.16

Compare Source

v4.2.15

Compare Source

v4.2.14

Compare Source

v4.2.13

Compare Source

v4.2.12

Compare Source

v4.2.11

Compare Source

v4.2.10

Compare Source

v4.2.9

Compare Source

v4.2.8

Compare Source

v4.2.7

Compare Source

v4.2.6

Compare Source

v4.2.5

Compare Source

v4.2.4

Compare Source


Configuration

📅 Schedule: At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box.

This PR has been generated by WhiteSource Renovate. View repository job log here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants