Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@0no-co/graphql.web

Package Overview
Dependencies
Maintainers
1
Versions
41
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@0no-co/graphql.web - npm Package Compare versions

Comparing version 0.0.0-canary-20230320192911 to 0.0.0-canary-20230321105032

3

dist/graphql.web.d.ts

@@ -427,3 +427,2 @@ type Maybe<T> = T | undefined | null;

declare function blockString(string: string): string;
type ParseOptions = {

@@ -466,2 +465,2 @@ [option: string]: any;

export { ASTNode, ASTReducer, ASTVisitFn, ASTVisitor, ArgumentNode, BREAK, BooleanValueNode, ConstArgumentNode, ConstDirectiveNode, ConstListValueNode, ConstObjectFieldNode, ConstObjectValueNode, ConstValueNode, DefinitionNode, DirectiveDefinitionNode, DirectiveNode, DocumentNode, EnumTypeDefinitionNode, EnumTypeExtensionNode, EnumValueDefinitionNode, EnumValueNode, ExecutableDefinitionNode, FieldDefinitionNode, FieldNode, FloatValueNode, FragmentDefinitionNode, FragmentSpreadNode, GraphQLError, InlineFragmentNode, InputObjectTypeDefinitionNode, InputObjectTypeExtensionNode, InputValueDefinitionNode, IntValueNode, InterfaceTypeDefinitionNode, InterfaceTypeExtensionNode, Kind, ListTypeNode, ListValueNode, Location, NameNode, NamedTypeNode, NonNullTypeNode, NullValueNode, ObjectFieldNode, ObjectTypeDefinitionNode, ObjectTypeExtensionNode, ObjectValueNode, OperationDefinitionNode, OperationTypeDefinitionNode, OperationTypeNode, ScalarTypeDefinitionNode, ScalarTypeExtensionNode, SchemaDefinitionNode, SchemaExtensionNode, SelectionNode, SelectionSetNode, Source, StringValueNode, TypeDefinitionNode, TypeExtensionNode, TypeNode, TypeSystemDefinitionNode, TypeSystemExtensionNode, UnionTypeDefinitionNode, UnionTypeExtensionNode, ValueNode, VariableDefinitionNode, VariableNode, blockString, parse, parseType, parseValue, print, printBlockString, printString, valueFromASTUntyped, valueFromTypeNode, visit };
export { ASTNode, ASTReducer, ASTVisitFn, ASTVisitor, ArgumentNode, BREAK, BooleanValueNode, ConstArgumentNode, ConstDirectiveNode, ConstListValueNode, ConstObjectFieldNode, ConstObjectValueNode, ConstValueNode, DefinitionNode, DirectiveDefinitionNode, DirectiveNode, DocumentNode, EnumTypeDefinitionNode, EnumTypeExtensionNode, EnumValueDefinitionNode, EnumValueNode, ExecutableDefinitionNode, FieldDefinitionNode, FieldNode, FloatValueNode, FragmentDefinitionNode, FragmentSpreadNode, GraphQLError, InlineFragmentNode, InputObjectTypeDefinitionNode, InputObjectTypeExtensionNode, InputValueDefinitionNode, IntValueNode, InterfaceTypeDefinitionNode, InterfaceTypeExtensionNode, Kind, ListTypeNode, ListValueNode, Location, NameNode, NamedTypeNode, NonNullTypeNode, NullValueNode, ObjectFieldNode, ObjectTypeDefinitionNode, ObjectTypeExtensionNode, ObjectValueNode, OperationDefinitionNode, OperationTypeDefinitionNode, OperationTypeNode, ScalarTypeDefinitionNode, ScalarTypeExtensionNode, SchemaDefinitionNode, SchemaExtensionNode, SelectionNode, SelectionSetNode, Source, StringValueNode, TypeDefinitionNode, TypeExtensionNode, TypeNode, TypeSystemDefinitionNode, TypeSystemExtensionNode, UnionTypeDefinitionNode, UnionTypeExtensionNode, ValueNode, VariableDefinitionNode, VariableNode, parse, parseType, parseValue, print, printBlockString, printString, valueFromASTUntyped, valueFromTypeNode, visit };

@@ -36,3 +36,4 @@ Object.defineProperty(exports, "__esModule", {

return {
...this
...this,
message: this.message
};

@@ -115,11 +116,11 @@ }

var o = /[-]?\d+/y;
var o = /-?\d+/y;
var l = /(?:[-]?\d+)?(?:\.\d+)(?:[eE][+-]?\d+)?/y;
var l = /(?:\.\d+)?(?:[eE][+-]?\d+)?/y;
var u = /\\/g;
var d = /"""(?:[\s\S]+(?="""))?"""/y;
var v = /"""(?:[\s\S]+(?="""))?"""/y;
var v = /"(?:[^"\r\n]+)?"/y;
var d = /"(?:[^"\r\n]+)?"/y;

@@ -144,12 +145,15 @@ function value(i) {

};
} else if (c = advance(l)) {
s = {
kind: "FloatValue",
value: c
};
} else if (c = advance(o)) {
s = {
kind: "IntValue",
value: c
};
var f = c;
if (c = advance(l)) {
s = {
kind: "FloatValue",
value: f + c
};
} else {
s = {
kind: "IntValue",
value: f
};
}
} else if (c = advance(n)) {

@@ -160,3 +164,3 @@ s = {

};
} else if (c = advance(d)) {
} else if (c = advance(v)) {
s = {

@@ -167,3 +171,3 @@ kind: "StringValue",

};
} else if (c = advance(v)) {
} else if (c = advance(d)) {
s = {

@@ -461,5 +465,2 @@ kind: "StringValue",

var t = type();
if (!t) {
throw error("VariableDefinition");
}
var o = void 0;

@@ -692,4 +693,2 @@ if (61 === e.charCodeAt(r)) {

exports.blockString = blockString;
exports.parse = function parse(i, n) {

@@ -699,14 +698,11 @@ e = "string" == typeof i.body ? i.body : i;

return function document() {
var i;
var e;
ignored();
var n = [];
while (i = fragmentDefinition() || operationDefinition()) {
n.push(i);
var r = [];
while (e = fragmentDefinition() || operationDefinition()) {
r.push(e);
}
if (r !== e.length) {
throw error("Document");
}
return {
kind: "Document",
definitions: n
definitions: r
};

@@ -719,7 +715,3 @@ }();

r = 0;
var t = type();
if (!t) {
throw error("TypeNode");
}
return t;
return type();
};

@@ -801,4 +793,4 @@

}
var d;
var v = {
var v;
var d = {
...e

@@ -815,12 +807,10 @@ };

n.push(p);
d = traverse(c[p], p, c);
v = traverse(c[p], p, c);
n.pop();
i.pop();
if (void 0 === d) {
f.push(c[p]);
} else if (null === d) {
if (null == v) {
o = !0;
} else {
o = o || d !== c[p];
f.push(d);
o = o || v !== c[p];
f.push(v);
}

@@ -831,5 +821,5 @@ }

} else if (null != c && "string" == typeof c.kind) {
if (void 0 !== (d = traverse(c, s, e))) {
o = o || c !== d;
c = d;
if (void 0 !== (v = traverse(c, s, e))) {
o = o || c !== v;
c = v;
}

@@ -839,3 +829,3 @@ }

if (o) {
v[s] = c;
d[s] = c;
}

@@ -853,5 +843,5 @@ }

} else if (void 0 !== u) {
return o ? v : u;
return o ? d : u;
} else {
return o ? v : e;
return o ? d : e;
}

@@ -858,0 +848,0 @@ }(e);

{
"name": "@0no-co/graphql.web",
"description": "A spec-compliant client-side GraphQL implementation",
"version": "0.0.0-canary-20230320192911",
"version": "0.0.0-canary-20230321105032",
"author": "0no.co <hi@0no.co>",

@@ -67,2 +67,3 @@ "source": "./src/index.ts",

"@typescript-eslint/parser": "^5.55.0",
"@vitest/coverage-c8": "^0.29.7",
"dotenv": "^16.0.3",

@@ -84,3 +85,3 @@ "eslint": "^8.36.0",

"typescript": "^5.0.2",
"vitest": "^0.29.3"
"vitest": "^0.29.7"
},

@@ -91,3 +92,3 @@ "publishConfig": {

"scripts": {
"test": "vitest run",
"test": "vitest",
"check": "tsc",

@@ -94,0 +95,0 @@ "lint": "eslint --ext=js,ts .",

@@ -34,2 +34,16 @@ <div align="center">

### Overview
`@0no-co/graphql.web` aims to provide a minimal set of exports to implement
client-side GraphQL utilities, mostly including parsing, printing, and visiting
the GraphQL AST, and the `GraphQLError` class.
Currently, `graphql.web` compresses to under 4kB and doesn’t regress on
GraphQL.js’ performance when parsing, printing, or visiting the AST.
For all primary APIs we aim to hit 100% test coverage and match the output,
types, and API compatibility of GraphQL.js, including — as far as possible
— TypeScript type compatibility of the AST types with the currently stable
version of GraphQL.js.
### API

@@ -36,0 +50,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc