Open habdelra opened 4 years ago
how can I solve the issue on my end, is there a work around. The below is the line, to creating the issue in my main build index.js
when I am trying to use my package
const baseUrl = URL.pathToFileURL(process.cwd() + '/');
I tried rollup node resolve, made url:true
and installed a local url
package.. still getting the same issue.
TypeError: URL.pathToFileURL is not a function
This error happened while generating the page. Any console logs will be displayed in the terminal window.
I am using the package in a nextjs app
The url polyfill is missing the
pathToFileURL()
function, as documented here: https://nodejs.org/api/url.html#url_url_pathtofileurl_path