As @31Py said, you can reference using ../node_modules/path/to/the/package
OR
It's always better to create separate dependencies in package.json
file for public folder(front end code). This helps you to organize both the code separate, while bundling front end, running task runners(grunt, gulp) and you would know which packages are for front end.
In index.html referencing the node modules will be /node_modules/path/to/the/package
Some reference Links with comments in the section.
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.