-
|
Hey friends! Thanks for the amazing project. Is there a way to make Urql slimmer by avoiding having the extra dependency of |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
|
Yes, and no. Let me elaborate. 😅 Is it easly possible to bundle nothing from The dependencies in import { GraphQLError } from "graphql/error/GraphQLError.mjs";
import { parse } from "graphql/language/parser.mjs";
import { print } from "graphql/language/printer.mjs";
import { Kind } from "graphql/language/kinds.mjs";Here we can see the entrypoints of what is used on a basic level. You can ignore That brings us to If I'm not mistaken though the total impact of What about Graphcache? This pulls in (additionally): import { valueFromASTUntyped } from "graphql/utilities/valueFromASTUntyped.mjs";
import { isNullableType, isNonNullType, isListType, GraphQLObjectType, GraphQLInterfaceType, GraphQLUnionType } from "graphql/type/definition.mjs";
import { buildClientSchema } from "graphql/utilities/buildClientSchema.mjs";The The large question you're asking is: How much of an impact does The big one here is still So, at this point, I could go on, but basically the impact is pretty overseeable. I'd love to get more accurate numbers behind this, but it's always a little elusive as there's been changes in Anyway, the tl;dr is |
Beta Was this translation helpful? Give feedback.
Yes, and no. Let me elaborate. 😅
Is it easly possible to bundle nothing from
graphql? Absolutely not. There are several things that you could alias away to get rid of them, sure, but ultimately there are some dependencies that are more or less important. But that's not a bad thing. Let me explain how this makes sense, what you can do, and what makes sense to do.The dependencies in
@urql/coreyou'll see are:Here we can see the entrypoints of what is used on a basic level…