Closed denneulin closed 7 years ago
this is intended to provide the node libraries in the browser where they are not available. just do a regular require for the node builtins you need, rollup should ignore it and lambda has the built in modules
thanks for your help ;)
Hi! I am hitting the same issue. In the code I don't have any imports for node builtins and I am still seeing this. How can I by pass this error?
I was able to fix the problem by swapping this:
import got from 'got'
with that:
const got = require('got')
Hi,
I am using you plugin to bundle my project. I am trying to include node_modules into bundle in order to deploy on AWS Lambda.
When I use rollup-plugin-node-builtins with rollup-plugin-node-globals, my bundle.js can not be used because of the line 20 of es6/http-lib/capability.js :
xhr = new global.XMLHttpRequest()
XMLHttpRequest does not exist on Node.js API.
What have I missed ?