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

enhance(utils/isUrl): use URL.canParse when available #6891

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

ardatan
Copy link
Owner

@ardatan ardatan commented Jan 24, 2025

  • New isUrl helper, and it uses URL.canParse if available

URL.canParse is faster than using new URL constructor to check if the string is URL

Copy link

changeset-bot bot commented Jan 24, 2025

🦋 Changeset detected

Latest commit: cf92675

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 26 packages
Name Type
@graphql-tools/utils Minor
@graphql-tools/executor Patch
@graphql-tools/graphql-tag-pluck Patch
@graphql-tools/import Patch
@graphql-tools/links Patch
@graphql-tools/load Patch
@graphql-tools/merge Patch
@graphql-tools/mock Patch
@graphql-tools/node-require Patch
@graphql-tools/relay-operation-optimizer Patch
@graphql-tools/resolvers-composition Patch
@graphql-tools/schema Patch
@graphql-tools/apollo-engine-loader Patch
@graphql-tools/code-file-loader Patch
@graphql-tools/git-loader Patch
@graphql-tools/github-loader Patch
@graphql-tools/graphql-file-loader Patch
@graphql-tools/json-file-loader Patch
@graphql-tools/module-loader Patch
@graphql-tools/url-loader Patch
@graphql-tools/executor-apollo-link Patch
@graphql-tools/executor-envelop Patch
@graphql-tools/executor-legacy-ws Patch
@graphql-tools/executor-urql-exchange Patch
@graphql-tools/executor-yoga Patch
graphql-tools Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@theguild-bot
Copy link
Collaborator

🚀 Snapshot Release (alpha)

The latest changes of this PR are available as alpha on npm (based on the declared changesets):

Package Version Info
@graphql-tools/executor 1.3.13-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/executor-apollo-link 1.0.13-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/executor-envelop 3.0.20-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/executor-legacy-ws 1.1.11-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/executor-urql-exchange 1.0.13-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/executor-yoga 3.0.20-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/graphql-tag-pluck 8.3.13-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
graphql-tools 9.0.12-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/import 7.0.12-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/links 9.0.21-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/load 8.0.13-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/apollo-engine-loader 8.0.14-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/code-file-loader 8.1.14-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/git-loader 8.0.18-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/github-loader 8.0.14-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/graphql-file-loader 8.0.13-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/json-file-loader 8.0.12-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/module-loader 8.0.12-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/url-loader 8.0.25-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/merge 9.0.18-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/mock 9.0.16-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/node-require 7.0.14-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/relay-operation-optimizer 7.0.13-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/resolvers-composition 7.0.12-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/schema 10.0.17-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎
@graphql-tools/utils 10.8.0-alpha-20250124175511-cf926757b2731edb762be661f8671ed41d778b2f npm ↗︎ unpkg ↗︎

Copy link
Contributor

💻 Website Preview

The latest changes are available as preview in: https://792e9d47.graphql-tools.pages.dev

@ardatan ardatan changed the title Url can parse enhance(utils/isUrl): use URL.canParse when available Jan 24, 2025
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