Git Product home page Git Product logo

Comments (15)

aymeric75 avatar aymeric75 commented on July 17, 2024 1

Thanks a lot, it's working now !

So what I did, in two separate terminals and in this order:

  • expo run:android
  • npx expo start --dev-client

from react-native-image-colors.

osamaqarem avatar osamaqarem commented on July 17, 2024

hey, I think you missed a step from the instructions. You have to run expo run:ios or expo run:android after expo prebuild.

from react-native-image-colors.

aymeric75 avatar aymeric75 commented on July 17, 2024

But "expo run:ios" can be ran only on a Mac no ? then we lose the advantage of using Expo

from react-native-image-colors.

osamaqarem avatar osamaqarem commented on July 17, 2024

yea that is right. but that is the point of the prebuild command. unfortunate because this library contains custom native code so we need to create a new "expo dev client" which has this new native code.

I'm not sure but I think eas build might have some kind of workflow for windows users to develop for iOS (I heard they have a free tier but I cant help here).

from react-native-image-colors.

aymeric75 avatar aymeric75 commented on July 17, 2024

Thanks, so it means that I cannot access the app via Expo Go ?

from react-native-image-colors.

aymeric75 avatar aymeric75 commented on July 17, 2024

Also when doing these steps on a mac: I get "Failed to install CocoaPods CLI with gem" .. should I run "npx pod-install" before running "npx expo prebuild" command ?

from react-native-image-colors.

osamaqarem avatar osamaqarem commented on July 17, 2024

I think that is run automatically as part of the prebuild command.
The error hints to me that your environment could be misconfigured. If this is the first time you're building native code on this machine (even if it's with expo) I think you need to make sure to do the environment setup here for 'React Native CLI > MacOS > iOS'.

from react-native-image-colors.

aymeric75 avatar aymeric75 commented on July 17, 2024

I have the React Native CLI option, I get the same error. Did you manage to run it on IOS ? if yes could you send me the compiled app ?

from react-native-image-colors.

osamaqarem avatar osamaqarem commented on July 17, 2024

sorry, but thats not a reasonable request. please try to follow what I suggested in my previous comment for configuring your environment or try to search for the errors your experiencing in setting up your app.
in any case I think these issues are outside the scope of this library and we should close this issue.

from react-native-image-colors.

aymeric75 avatar aymeric75 commented on July 17, 2024

Hello again,

I have created a repo with all the instruction (README.md) to reproduce the error: https://github.com/aymeric75/ExpoProject

Thank you

from react-native-image-colors.

osamaqarem avatar osamaqarem commented on July 17, 2024

hey! I tried the project but couldn't do this (from the README):

Then, once the app starts go to select an image on the left column

this is what I see once the app starts:

from react-native-image-colors.

aymeric75 avatar aymeric75 commented on July 17, 2024

Sorry I am going to update the App.js now

from react-native-image-colors.

aymeric75 avatar aymeric75 commented on July 17, 2024

Done, thanks !

from react-native-image-colors.

osamaqarem avatar osamaqarem commented on July 17, 2024

hey, so I was able to follow the instructions but I didn't run into the error again. however I think I got the problem you're having now. I think you should not use npx expo start but npx expo start --dev-client instead. I assumed the app would launch automatically for you after running expo run:ios/expo run:android and you would skip expo start.

here is an image showing the difference. the app icon with an X underneath is the Expo Go app created with the npx expo start command. don't use this one anymore. since we are adding custom native code, what we need here is the custom dev client which got installed when we ran expo run:ios/expo run:android. now that it is installed, use npx expo start --dev-client from now on to start the dev server and open the app with your project name. hope this helps!

from react-native-image-colors.

rsys2022 avatar rsys2022 commented on July 17, 2024

Hey i am getting this error on Apple TV
TypeError: null is not an object (evaluating '_$$_REQUIRE(_dependencyMap[4], "./module").RNImageColors.getColors')
i am using react native cli

working platform

  1. android mobile
  2. android TV
  3. iOS mobile

Libraries

  1. "react-native-image-colors": "^1.5.1",
  2. "react": "17.0.2",
  3. "react-native": "npm:[email protected]",

Using this line of code
const result = await ImageColors.getColors(url, {
fallback: '#4d5152',
cache: false,
key: url,
})

Please help, i am stuck here.

from react-native-image-colors.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.