Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

replaced url package with URL constructor #166

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

IvanKalinin
Copy link

This PR solved #149 by replacing url dependency with the native URL() constructor.

This constructor supports by Node.js since v6.13 https://developer.mozilla.org/en-US/docs/Web/API/URL/URL
The minimum Node.js version is 18 according to package.json requirements.

@ospfranco
Copy link
Collaborator

Does this run in React Native?

@IvanKalinin
Copy link
Author

Good question.
It seems like there might be some issues with React Native.
As an option, React Native developers can include a polyfill.
facebook/react-native#38656 (comment)

Also, I think it is still a good idea to eliminate as many dependencies as possible for the web, reduce the bundle size, follow the standards as much as possible, make the polyfills optional, and use them where we actually need them.

@ospfranco
Copy link
Collaborator

I will keep this open but not merge it, maybe some time in the future. No need to break what is working for the sake of only one platform.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants