Which node_modules will run in React Native? How can we test for this?
Thread Tags
Adobe Illustrator Adobe InDesign Adobe Photoshop Android Development Android Programming Android Studio Automation Testing C / C++ Programming Career Options College Lounge css digital marketing Digital Marketing / SEO Fireworks Graphic Design Graphic designing Graphics Design Graphics Designing HTML? Illustrator Internship Training logo Design logo designing Magento Photoshop PHP Programming QA react-native Scroll Website SEO Single Page Website Stock Managment System Testing Typography UI UI/UX Development UI Design UI Designing UI development User Interface UX Design Web Designing Website Design Wordpress wpRegister for free!
Registration at Smart Mentors is completely free and takes only a few seconds. By registering you’ll gain:
- Full Posting Privileges.
- Access to Private Messaging.
- Optional Email Notification.
- Ability to Fully Participate.
Register Now, or check out the Site Tour and find out everything Smart Mentors has to offer.
This thread contains 1 reply, has 2 voices, and was last updated by darshan.soni007 2 years, 2 months ago.
- Author Replies
- January 25, 2019 at 12:18 pm #52575
Which node_modules will run in React Native? How can we test for this?
- January 25, 2019 at 12:20 pm #52576
Any simple JavaScript library that does not depend on Node.js runtime modules, and does not rely on web-specific concepts (e.g. window.location.pathname) will run fine in React Native. But we have to be careful because there’s no way to test for this with Babel. it doesn’t scan these libraries for offending dependencies. A module that uses window.location.pathname may fail at runtime in an unexpected place.
For modules that explicitly depend on Node.js runtime modules, we can often use Babel plugins to browserify these elements for use in React Native.
- AuthorPosts
You must be logged in to reply to this thread.Please login or register. Registration is 100% free.