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

@graphql-tools/import

Package Overview
Dependencies
Maintainers
3
Versions
883
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@graphql-tools/import - npm Package Compare versions

Comparing version 7.0.0 to 7.0.1-alpha-20240222154539-b27ae8605c354eed2b24844a475c8889ccc90dfb

10

cjs/index.js

@@ -5,7 +5,7 @@ "use strict";

const tslib_1 = require("tslib");
const graphql_1 = require("graphql");
const fs_1 = require("fs");
const path_1 = require("path");
const process_1 = require("process");
const graphql_1 = require("graphql");
const resolve_from_1 = tslib_1.__importDefault(require("resolve-from"));
const process_1 = require("process");
const utils_1 = require("@graphql-tools/utils");

@@ -133,3 +133,4 @@ const builtinTypes = ['String', 'Float', 'Int', 'Boolean', 'ID', 'Upload'];

// If that dependency cannot be found both in imports and this file, throw an error
if (!allImportedDefinitionsMap.has(dependencyName) && !definitionsByName.has(dependencyName)) {
if (!allImportedDefinitionsMap.has(dependencyName) &&
!definitionsByName.has(dependencyName)) {
throw new Error(`Couldn't find type ${dependencyName} in any of the schemas.`);

@@ -440,3 +441,4 @@ }

typeName,
...(node.interfaces?.map((namedTypeNode) => namedTypeNode.name.value) || []),
...(node.interfaces?.map((namedTypeNode) => namedTypeNode.name.value) ||
[]),
];

@@ -443,0 +445,0 @@ node.interfaces?.forEach((namedTypeNode) => {

12

esm/index.js

@@ -1,6 +0,6 @@

import { Source, parse, Kind, print, } from 'graphql';
import { readFileSync, realpathSync } from 'fs';
import { dirname, join, isAbsolute } from 'path';
import { dirname, isAbsolute, join } from 'path';
import { cwd as cwdFactory } from 'process';
import { Kind, parse, print, Source, } from 'graphql';
import resolveFrom from 'resolve-from';
import { cwd as cwdFactory } from 'process';
import { parseGraphQLSDL } from '@graphql-tools/utils';

@@ -127,3 +127,4 @@ const builtinTypes = ['String', 'Float', 'Int', 'Boolean', 'ID', 'Upload'];

// If that dependency cannot be found both in imports and this file, throw an error
if (!allImportedDefinitionsMap.has(dependencyName) && !definitionsByName.has(dependencyName)) {
if (!allImportedDefinitionsMap.has(dependencyName) &&
!definitionsByName.has(dependencyName)) {
throw new Error(`Couldn't find type ${dependencyName} in any of the schemas.`);

@@ -430,3 +431,4 @@ }

typeName,
...(node.interfaces?.map((namedTypeNode) => namedTypeNode.name.value) || []),
...(node.interfaces?.map((namedTypeNode) => namedTypeNode.name.value) ||
[]),
];

@@ -433,0 +435,0 @@ node.interfaces?.forEach((namedTypeNode) => {

{
"name": "@graphql-tools/import",
"version": "7.0.0",
"version": "7.0.1-alpha-20240222154539-b27ae8605c354eed2b24844a475c8889ccc90dfb",
"description": "A set of utils for faster development of GraphQL tools",

@@ -10,3 +10,3 @@ "sideEffects": false,

"dependencies": {
"@graphql-tools/utils": "^10.0.0",
"@graphql-tools/utils": "^10.0.13",
"resolve-from": "5.0.0",

@@ -13,0 +13,0 @@ "tslib": "^2.4.0"

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