Invoking a node module from react component
问题 How do I use Node Modules for example 'lwip' in React component ? This is for an electron application. Updating the question with Code: This is the react component from which I am trying to invoke another .js file. button.js import React from 'react'; import ReactDOM from 'react-dom'; import resize from '../../node-code/process'; class Button extends React.Component{ mess(){ console.log('working'); resize(); } render(){ return <button id="imgButton" onClick={this.mess.bind(this)}>Upload Image