react-native-yunolink
Workaround for symlinks in React Native
Last updated 6 months ago by swaagie .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install react-native-yunolink 
SYNC missed versions from official npm registry.

react-native-yunolink

Workaround for using symlinks in React Native.

oclif Version Downloads/week License

Usage

Install the module globally.

npm install -g react-native-yunolink

and execute it in the root of a repository where you want to use the targetted Node.JS module(s). It supports multiple targets by separating each path with a whitespace. In addition this will temporarily update the watchFolders property in metro.config.js to force Metro bundler to also watch your targetted modules.

rn-link [...targets]

rn-link ../myModule1 ../myModule2

Or alternatively install the module as devDependency.

npm install -D react-native-yunolink

And watch and copy the module from your package.json by adding a scripts command.

"scripts": {
  "watch-modules": "rn-link ../myModule1 ../myModule2"
}

Run it with npm run watch-myModule.

Commands

The CLI only has a single command available to start the module sync. If you need to ignore additional files or folders pass a comma separated list to -i or --ignore. Ensure you always provide [...targets] to rn-link.

If you want metro bundler to watch the linked folder for file changes and rebuild automatically, provide the -w flag. Watching files is only possible if the symlinked folder has no duplicate modules in node_modules.

In addition, -v and -h are available for version description and help.

Module tree

This module operates under the assumption npm or yarn dedupe node_modules to the root of your app. The node_modules of the synced target will be excluded. This will prevent @ProvidesModule errors in metro bundler.

Current Tags

  • 2.2.0                                ...           latest (6 months ago)

13 Versions

  • 2.2.0                                ...           6 months ago
  • 2.1.5                                ...           a year ago
  • 2.1.4                                ...           a year ago
  • 2.1.3                                ...           a year ago
  • 2.1.1                                ...           a year ago
  • 2.1.0                                ...           a year ago
  • 2.0.3                                ...           a year ago
  • 2.0.2                                ...           a year ago
  • 2.0.1                                ...           a year ago
  • 2.0.0                                ...           a year ago
  • 1.0.2                                ...           a year ago
  • 1.0.1                                ...           a year ago
  • 1.0.0                                ...           a year ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 2
Dependencies (7)
Dev Dependencies (4)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |