0

There is a library react-native-iron-source on GitHub. But this library is not in the npm.

How can I add the library to my react-native project manually? So that it works correctly with js code, iOS and Android?

Ivan Kramarchuk
  • 226
  • 6
  • 17
  • are you sure that [react-native-iron-source](https://github.com/squaretwo/react-native-iron-source) is not in `NPM`? – flix Apr 04 '18 at 11:49
  • read [readme](https://github.com/squaretwo/react-native-iron-source#getting-started) file correctly – Shahzad Apr 04 '18 at 11:49
  • @flix Yes: "npm ERR! 404 Not Found: react-native-iron-source@latest" – Ivan Kramarchuk Apr 04 '18 at 11:51
  • give me a full link of the library that you mention above, ill try to install it on my project, _Also try to `npm install react-native-iron-source --save` without `@latest`_ – flix Apr 04 '18 at 11:52
  • @ShahzadMirza Readme doesn't work correctly – Ivan Kramarchuk Apr 04 '18 at 11:53
  • @flix https://github.com/squaretwo/react-native-iron-source – Ivan Kramarchuk Apr 04 '18 at 11:55
  • yeah [read this issues](https://github.com/squaretwo/react-native-iron-source/issues/2#issuecomment-291286185) to the repo author doesn't even find time to add explanation that why its no available on npm. – Shahzad Apr 04 '18 at 11:56
  • @ShahzadMirza yes, I read the issue. But, the issue is one year. I would like know how to add the library manually without npm repository – Ivan Kramarchuk Apr 04 '18 at 12:04
  • this [SO question](https://stackoverflow.com/questions/5786433/how-to-install-a-node-js-module-without-using-npm) will be helpful for adding the package – Shahzad Apr 04 '18 at 12:04
  • @IvanKramarchuk putting repo as your dependency as mentioned in Answer and start npm again – Revansiddh Apr 04 '18 at 12:24

1 Answers1

2

Try putting this in package.json

 "dependencies": {
         ...
        "react-native-iron-source": "git://github.com/bsy/react-native-iron-source.git"
    },
Revansiddh
  • 2,932
  • 3
  • 19
  • 33