Here is a file named tableau.js without npm package. I want to use it in my project? However, I cann't solve this problem. Please help me and show me correct ways. Thanks!
You need to use export module to export variables and functions from a file to another. Import your stuff to your main file. See https://www.sitepoint.com/understanding-module-exports-exports-node-js/
You could also use http://www.tutorialsteacher.com/nodejs/nodejs-module-exports
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.