drei icon indicating copy to clipboard operation
drei copied to clipboard

useDetectGPU pointing to 3.x version

Open liqueflies opened this issue 3 years ago • 4 comments

  • three version: 0.135.0
  • @react-three/fiber version: 7.0.24
  • @react-three/drei version: 8.4.0
  • node version: 14
  • npm (or yarn) version:

Problem description:

Hello, the function useDetectGPU is pointing to a 3.x version on dependencies so it's not working good to iPhone, M1 chips etc... detect-gpu is now at 4.x version

Suggested solution:

Just update the version on the dependency list! For now I installed the fresh version of detect-gpu and copied the drei useDetectGPU file into my utils.

Thank you!

liqueflies avatar Jan 11 '22 11:01 liqueflies

Feel free to make a PR to address this issue 😄

joshuaellis avatar Jan 11 '22 13:01 joshuaellis

👍 Is good to put dependencies as "latest" as is maintained by pmndrs?

liqueflies avatar Jan 11 '22 13:01 liqueflies

I wouldn't just incase there's a breaking change (e.g. v5) that we haven't seen. PMNDRS is a very large org, we're not watching all repos!

joshuaellis avatar Jan 11 '22 14:01 joshuaellis

The v4 bump came from https://github.com/pmndrs/detect-gpu/commit/00b4c619b5a822ab0b009c9ca87ad0726be48c67. Doesn't look like anything as far as the public API changed.

CodyJasonBennett avatar Jan 29 '22 12:01 CodyJasonBennett