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

experiment(native): implement missing Blob/URL/fetch APIs #2982

Merged
merged 20 commits into from Sep 4, 2023

Conversation

CodyJasonBennett
Copy link
Member

@CodyJasonBennett CodyJasonBennett commented Aug 31, 2023

Fixes #1972, #2577.

Adds a fast path for data URIs in JSI, fixes for drawables in Android APK, and implements missing APIs as per the title.

Below asset is from https://github.com/KhronosGroup/glTF-Sample-Models/blob/master/2.0/Duck/glTF-Binary/Duck.glb, rendered on iOS emulator.


To recap, this issue comes from usage of URL.createObjectUrl(new Blob([arrayBuffer], { type: 'image/png' })) which is used by GLTFLoader to create a valid image url from inlined buffer data. react-native does not implement the Blob constructor from ArrayBuffer parts, nor does it URL.createObjectURL in the networking stack. Furthermore, only recently in 0.72 react-native implements FileReader.readAsArrayBuffer with facebook/react-native#36332 which is possible to polyfill for older versions. This previously necessitated patches for loaders since THREE.FileLoader moved to fetch -- facebook/react-native#30769 (comment).

I've been able to implement the missing Blob and URL.createObjectURL methods as a JS polyfill in lieu of mrousavy/react-native-blob-jsi-helper (we can't ship native code), but run into the same issue as #1972 (comment) when this is requested anywhere -- NSURLErrorDomain Code=-1002 "unsupported URL".

Show code:
import { NativeModules } from 'react-native'
import BlobManager from 'react-native/Libraries/Blob/BlobManager.js'
import { fromByteArray } from 'base64-js'

let BLOB_URL_PREFIX = null

const { BlobModule } = NativeModules

if (BlobModule && typeof BlobModule.BLOB_URI_SCHEME === 'string') {
  BLOB_URL_PREFIX = BlobModule.BLOB_URI_SCHEME + ':'
  if (typeof BlobModule.BLOB_URI_HOST === 'string') {
    BLOB_URL_PREFIX += `//${BlobModule.BLOB_URI_HOST}/`
  }
}

function uuidv4() {
  return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {
    const r = (Math.random() * 16) | 0,
      v = c == 'x' ? r : (r & 0x3) | 0x8
    return v.toString(16)
  })
}

BlobManager.createFromParts = function createFromParts(parts, options) {
  const blobId = uuidv4()

  const items = parts.map((part) => {
    if (part instanceof ArrayBuffer || (global.ArrayBufferView && part instanceof global.ArrayBufferView)) {
      const data = fromByteArray(new Uint8Array(part))
      return {
        data,
        type: 'string',
      }
    } else if (part instanceof Blob) {
      return {
        data: part.data,
        type: 'blob',
      }
    } else {
      return {
        data: String(part),
        type: 'string',
      }
    }
  })
  const size = items.reduce((acc, curr) => {
    if (curr.type === 'string') {
      return acc + global.unescape(encodeURI(curr.data)).length
    } else {
      return acc + curr.data.size
    }
  }, 0)

  BlobModule.createFromParts(items, blobId)

  return BlobManager.createFromOptions({
    blobId,
    offset: 0,
    size,
    type: options ? options.type : '',
    lastModified: options ? options.lastModified : Date.now(),
  })
}

URL.createObjectURL = function createObjectURL(blob) {
  if (BLOB_URL_PREFIX === null) {
    throw new Error('Cannot create URL for blob!')
  }
  return `${BLOB_URL_PREFIX}${blob.data.blobId}?offset=${blob.data.offset}&size=${blob.size}`
}

I notice that react-native adds special Blob handling to XMLHttpRequest (source) with similar mechanisms in FileReader (facebook/react-native#22681 (comment)), but this will need to be implemented in a polyfill here since user-land code will assume functional behavior. This notably won't work for code that uses fetch or other means like expo-asset. All of these problems stem from facebook/react-native#22681, which was unfortunately closed as stale.

Combining XMLHttpRequest with FileReader lets me get a handle on the blob data after it's converted into a URI, with EXGL giving special treatment to { localUri } for image data. This correctly implements Blob up to this point, and Image.getSize reports the right dimensions. I'm getting OOM crashes from EXGL when passing large data urls through JSI, so they're offloaded to the filesystem as a uri. Performance still needs to be measured and tweaked, but this finally solves this issue with a path to upstream fixes. Native support should remove the overhead of base64 encoding back and forth.

Show code:
// from glTF loader, passed to TextureLoader
const uri = URL.createObjectURL(new Blob([...], { type: '...' }))

const blob = await new Promise((res, rej) => {
  const xhr = new XMLHttpRequest()
  xhr.open('GET', uri)
  xhr.responseType = 'blob'
  xhr.onload = () => res(xhr.response)
  xhr.onerror = rej
  xhr.send()
})

const data = await new Promise((res, rej) => {
  const reader = new FileReader()
  reader.onload = () => res(reader.result)
  reader.onerror = rej
  reader.readAsText(blob)
})

const localUri = `data:${blob.type};base64,${data}`

const texture = new THREE.Texture()

const { width, height } = await new Promise((res, rej) =>
  Image.getSize(asset.localUri, (width, height) => res({ width, height }), rej),
)

texture.image = {
  data: { localUri },
  width,
  height,
}
texture.flipY = false
texture.unpackAlignment = 1
texture.needsUpdate = true

// @ts-ignore
texture.isDataTexture = true

@codesandbox-ci
Copy link

codesandbox-ci bot commented Aug 31, 2023

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 450774f:

Sandbox Source
example Configuration

@CodyJasonBennett CodyJasonBennett changed the title fix(native): special case data uris experiment(native): special case data uris Aug 31, 2023
@CodyJasonBennett CodyJasonBennett changed the title experiment(native): special case data uris experiment(native): implement missing Blob/URL/fetch APIs Aug 31, 2023
This should not be needed, Metro may be tree-shaking effectful code wrongly.
@XantreDev
Copy link

Looks great. Are you tested it on Android release mode.

@XantreDev
Copy link

Are you have plans to make some kind of prerelease npm tag with this fixes. Or please say when it will be released?)

@CodyJasonBennett CodyJasonBennett linked an issue Sep 4, 2023 that may be closed by this pull request
@wangzuo
Copy link

wangzuo commented Sep 13, 2023

It seems patching Blob will break existing fetch behaviour.

@CodyJasonBennett
Copy link
Member Author

Can you detail here or create an issue? I've been upstreaming that in particular to react-native and didn't harden fetch since it does not interact with the native BlobManager -- only XMLHttpRequest does. That is something else I want to address.

renovate bot added a commit to ziyadedher/ziyadedher that referenced this pull request Oct 4, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@react-three/fiber](https://togithub.com/pmndrs/react-three-fiber) |
[`8.13.0` ->
`8.14.4`](https://renovatebot.com/diffs/npm/@react-three%2ffiber/8.13.0/8.14.4)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@react-three%2ffiber/8.14.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@react-three%2ffiber/8.14.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@react-three%2ffiber/8.13.0/8.14.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@react-three%2ffiber/8.13.0/8.14.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>pmndrs/react-three-fiber (@&#8203;react-three/fiber)</summary>

###
[`v8.14.4`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.14.4)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.14.3...v8.14.4)

#### What's Changed

- fix(native): amend BlobManager over globals by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#3030

#### New Contributors

- [@&#8203;lin-stephanie](https://togithub.com/lin-stephanie) made their
first contribution in
[pmndrs/react-three-fiber#3024

**Full Changelog**:
pmndrs/react-three-fiber@v8.14.3...v8.14.4

###
[`v8.14.3`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.14.3)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.14.2...v8.14.3)

#### What's Changed

- fix(native): drop fsstat for react-native-web by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#3023

**Full Changelog**:
pmndrs/react-three-fiber@v8.14.2...v8.14.3

###
[`v8.14.2`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.14.2)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.14.1...v8.14.2)

#### What's Changed

- perf(native): don't double encode assets by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2996
- fix(useLoader): loosen Loader onError signature by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#3011

**Full Changelog**:
pmndrs/react-three-fiber@v8.14.1...v8.14.2

###
[`v8.14.1`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.14.1)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.14.0...v8.14.1)

#### What's Changed

- fix(native): prefer local uri for fs by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2993

**Full Changelog**:
pmndrs/react-three-fiber@v8.14.0...v8.14.1

###
[`v8.14.0`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.14.0):
8.14.0

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.9...v8.14.0)

##### What's Changed

- experiment(native): implement missing Blob/URL/fetch APIs by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2982
- feat(native): use PanResponder for react-native-web by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2985

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.9...v8.14.0

###
[`v8.13.9`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.9)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.8...v8.13.9)

#### What's Changed

- fix(native): TextureLoader should remain consistent with FileLoader by
[@&#8203;l3utterfly](https://togithub.com/l3utterfly) in
[pmndrs/react-three-fiber#2986

#### New Contributors

- [@&#8203;l3utterfly](https://togithub.com/l3utterfly) made their first
contribution in
[pmndrs/react-three-fiber#2986

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.8...v8.13.9

###
[`v8.13.8`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.8)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/8.13.7...v8.13.8)

#### What's Changed

- fix(useLoader): dispose loaders by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2984

#### New Contributors

- [@&#8203;GmBodhi](https://togithub.com/GmBodhi) made their first
contribution in
[pmndrs/react-three-fiber#2976

**Full Changelog**:
pmndrs/react-three-fiber@8.13.7...v8.13.8

###
[`v8.13.7`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/8.13.7)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.6...8.13.7)

#### What's Changed

- fix(Canvas): pass scene prop by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2975

#### New Contributors

- [@&#8203;GabeDahl](https://togithub.com/GabeDahl) made their first
contribution in
[pmndrs/react-three-fiber#2968

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.6...8.13.7

###
[`v8.13.6`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.6)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.5...v8.13.6)

#### What's Changed

- fix: harden XR init against Renderer shim by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2947

#### New Contributors

- [@&#8203;hood](https://togithub.com/hood) made their first
contribution in
[pmndrs/react-three-fiber#2898
- [@&#8203;Sargsian](https://togithub.com/Sargsian) made their first
contribution in
[pmndrs/react-three-fiber#2922
- [@&#8203;myznikovgleb](https://togithub.com/myznikovgleb) made their
first contribution in
[pmndrs/react-three-fiber#2935

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.5...v8.13.6

###
[`v8.13.5`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.5)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.4...v8.13.5)

#### What's Changed

- fix(types): remove reference to
[@&#8203;types/webxr](https://togithub.com/types/webxr) by
[@&#8203;Methuselah96](https://togithub.com/Methuselah96) in
[pmndrs/react-three-fiber#2919
- fix(types): harden colors overload since r153 by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2931

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.4...v8.13.5

###
[`v8.13.4`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.4)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/@react-three/fiber@8.13.3...v8.13.4)

##### What's Changed

- fix: safely diff instances by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2906

##### New Contributors

- [@&#8203;bhouston](https://togithub.com/bhouston) made their first
contribution in
[pmndrs/react-three-fiber#2896

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.2...v8.13.4

###
[`v8.13.3`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.3)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/@react-three/fiber@8.13.2...@react-three/fiber@8.13.3)

#### What's Changed

- fix: revert nestable portals, up suspend-react by
[@&#8203;drcmda](https://togithub.com/drcmda) in
[`05187c2`](https://togithub.com/pmndrs/react-three-fiber/commit/05187c22fcac8d480120ffe1133ebe85049cb552)

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.2...v8.13.3

###
[`v8.13.2`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.2)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.1...@react-three/fiber@8.13.2)

#### What's Changed

- fix: update suspend-react by
[@&#8203;drcmda](https://togithub.com/drcmda) in
[`95e71ae`](https://togithub.com/pmndrs/react-three-fiber/commit/95e71ae00e8ede868b9584891e8e9b04d54d0f4e)

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.1...v8.13.2

###
[`v8.13.1`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.1)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.0...v8.13.1)

#### What's Changed

- docs: update links to legacy react docs by
[@&#8203;ninofiliu](https://togithub.com/ninofiliu) in
[pmndrs/react-three-fiber#2858
- fix(core): unlink primitives on dispose by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2877
- fix(core): portals should be nestable by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2746

#### New Contributors

- [@&#8203;ninofiliu](https://togithub.com/ninofiliu) made their first
contribution in
[pmndrs/react-three-fiber#2858

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.0...v8.13.1

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **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.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/ziyadedher/ziyadedher).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4wLjMiLCJ1cGRhdGVkSW5WZXIiOiIzNy4wLjMiLCJ0YXJnZXRCcmFuY2giOiJtYWluIn0=-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
@Off2Race
Copy link

Off2Race commented Nov 2, 2023

Below asset is from https://github.com/KhronosGroup/glTF-Sample-Models/blob/master/2.0/Duck/glTF-Binary/Duck.glb, rendered on iOS emulator.

Hi, @CodyJasonBennett – My apologies for a slightly off-topic question but how are you rendering this on an iOS Simulator? I thought it was necessary to use actual iOS and Android devices for testing. In fact, when I try to use the simulator, all I get is a blank screen.

@CodyJasonBennett
Copy link
Member Author

I noticed that simulator occasionally pushes frames so I reloaded the app until one was presented.

@Off2Race
Copy link

Off2Race commented Nov 2, 2023

I noticed that simulator occasionally pushes frames so I reloaded the app until one was presented.

Thanks! I'll try that myself

@corysimmons
Copy link

Whoa, is this in? Can we do something like this now?

import { RNGltf, RNCanvas } from '@react-three/fiber'
import { View } from 'react-native'

<View>
  <RNCanvas>
    <RNGltf src="/foo.gltf" />
  </RNCanvas>
</View>

Also, does this work in both iOS and Android? Is it performant?

Sorry, I'm dying to use 3D in React Native. 😅

@CodyJasonBennett
Copy link
Member Author

See https://docs.pmnd.rs/react-three-fiber/getting-started/installation#react-native. Same as web, although /native targets give you correct IntelliSense.

ziyadedher pushed a commit to ziyadedher/ziyadedher that referenced this pull request Dec 16, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@react-three/fiber](https://togithub.com/pmndrs/react-three-fiber) |
[`8.13.0` ->
`8.14.4`](https://renovatebot.com/diffs/npm/@react-three%2ffiber/8.13.0/8.14.4)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@react-three%2ffiber/8.14.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@react-three%2ffiber/8.14.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@react-three%2ffiber/8.13.0/8.14.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@react-three%2ffiber/8.13.0/8.14.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>pmndrs/react-three-fiber (@&#8203;react-three/fiber)</summary>

###
[`v8.14.4`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.14.4)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.14.3...v8.14.4)

#### What's Changed

- fix(native): amend BlobManager over globals by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#3030

#### New Contributors

- [@&#8203;lin-stephanie](https://togithub.com/lin-stephanie) made their
first contribution in
[pmndrs/react-three-fiber#3024

**Full Changelog**:
pmndrs/react-three-fiber@v8.14.3...v8.14.4

###
[`v8.14.3`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.14.3)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.14.2...v8.14.3)

#### What's Changed

- fix(native): drop fsstat for react-native-web by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#3023

**Full Changelog**:
pmndrs/react-three-fiber@v8.14.2...v8.14.3

###
[`v8.14.2`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.14.2)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.14.1...v8.14.2)

#### What's Changed

- perf(native): don't double encode assets by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2996
- fix(useLoader): loosen Loader onError signature by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#3011

**Full Changelog**:
pmndrs/react-three-fiber@v8.14.1...v8.14.2

###
[`v8.14.1`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.14.1)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.14.0...v8.14.1)

#### What's Changed

- fix(native): prefer local uri for fs by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2993

**Full Changelog**:
pmndrs/react-three-fiber@v8.14.0...v8.14.1

###
[`v8.14.0`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.14.0):
8.14.0

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.9...v8.14.0)

##### What's Changed

- experiment(native): implement missing Blob/URL/fetch APIs by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2982
- feat(native): use PanResponder for react-native-web by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2985

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.9...v8.14.0

###
[`v8.13.9`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.9)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.8...v8.13.9)

#### What's Changed

- fix(native): TextureLoader should remain consistent with FileLoader by
[@&#8203;l3utterfly](https://togithub.com/l3utterfly) in
[pmndrs/react-three-fiber#2986

#### New Contributors

- [@&#8203;l3utterfly](https://togithub.com/l3utterfly) made their first
contribution in
[pmndrs/react-three-fiber#2986

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.8...v8.13.9

###
[`v8.13.8`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.8)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/8.13.7...v8.13.8)

#### What's Changed

- fix(useLoader): dispose loaders by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2984

#### New Contributors

- [@&#8203;GmBodhi](https://togithub.com/GmBodhi) made their first
contribution in
[pmndrs/react-three-fiber#2976

**Full Changelog**:
pmndrs/react-three-fiber@8.13.7...v8.13.8

###
[`v8.13.7`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/8.13.7)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.6...8.13.7)

#### What's Changed

- fix(Canvas): pass scene prop by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2975

#### New Contributors

- [@&#8203;GabeDahl](https://togithub.com/GabeDahl) made their first
contribution in
[pmndrs/react-three-fiber#2968

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.6...8.13.7

###
[`v8.13.6`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.6)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.5...v8.13.6)

#### What's Changed

- fix: harden XR init against Renderer shim by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2947

#### New Contributors

- [@&#8203;hood](https://togithub.com/hood) made their first
contribution in
[pmndrs/react-three-fiber#2898
- [@&#8203;Sargsian](https://togithub.com/Sargsian) made their first
contribution in
[pmndrs/react-three-fiber#2922
- [@&#8203;myznikovgleb](https://togithub.com/myznikovgleb) made their
first contribution in
[pmndrs/react-three-fiber#2935

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.5...v8.13.6

###
[`v8.13.5`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.5)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.4...v8.13.5)

#### What's Changed

- fix(types): remove reference to
[@&#8203;types/webxr](https://togithub.com/types/webxr) by
[@&#8203;Methuselah96](https://togithub.com/Methuselah96) in
[pmndrs/react-three-fiber#2919
- fix(types): harden colors overload since r153 by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2931

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.4...v8.13.5

###
[`v8.13.4`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.4)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/@react-three/fiber@8.13.3...v8.13.4)

##### What's Changed

- fix: safely diff instances by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2906

##### New Contributors

- [@&#8203;bhouston](https://togithub.com/bhouston) made their first
contribution in
[pmndrs/react-three-fiber#2896

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.2...v8.13.4

###
[`v8.13.3`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.3)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/@react-three/fiber@8.13.2...@react-three/fiber@8.13.3)

#### What's Changed

- fix: revert nestable portals, up suspend-react by
[@&#8203;drcmda](https://togithub.com/drcmda) in
[`05187c2`](https://togithub.com/pmndrs/react-three-fiber/commit/05187c22fcac8d480120ffe1133ebe85049cb552)

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.2...v8.13.3

###
[`v8.13.2`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.2)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.1...@react-three/fiber@8.13.2)

#### What's Changed

- fix: update suspend-react by
[@&#8203;drcmda](https://togithub.com/drcmda) in
[`95e71ae`](https://togithub.com/pmndrs/react-three-fiber/commit/95e71ae00e8ede868b9584891e8e9b04d54d0f4e)

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.1...v8.13.2

###
[`v8.13.1`](https://togithub.com/pmndrs/react-three-fiber/releases/tag/v8.13.1)

[Compare
Source](https://togithub.com/pmndrs/react-three-fiber/compare/v8.13.0...v8.13.1)

#### What's Changed

- docs: update links to legacy react docs by
[@&#8203;ninofiliu](https://togithub.com/ninofiliu) in
[pmndrs/react-three-fiber#2858
- fix(core): unlink primitives on dispose by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2877
- fix(core): portals should be nestable by
[@&#8203;CodyJasonBennett](https://togithub.com/CodyJasonBennett) in
[pmndrs/react-three-fiber#2746

#### New Contributors

- [@&#8203;ninofiliu](https://togithub.com/ninofiliu) made their first
contribution in
[pmndrs/react-three-fiber#2858

**Full Changelog**:
pmndrs/react-three-fiber@v8.13.0...v8.13.1

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **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.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/ziyadedher/ziyadedher).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4wLjMiLCJ1cGRhdGVkSW5WZXIiOiIzNy4wLjMiLCJ0YXJnZXRCcmFuY2giOiJtYWluIn0=-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
5 participants