Posts

Showing posts from February 6, 2019

Duplicate “graphql” modules cannot be used

Image
0 I have found that the graphql-js library does not allow dependencies to also use graphql. You would get the following error Duplicate "graphql" modules cannot be used at the same time since different versions may have different capabilities and behavior. The data from one version used in the function from another could produce confusing and spurious results. from the following code const express = require('express'); const graphqlHTTP = require('express-graphql'); const GraphQLSchema = require('graphql'); // the module graphql-test-mod-obj-type' has // graphql as a depenedency const myType = require('graphql-test-mod-obj-type'); const app = express(); const schema = new GraphQLSchema( query: myType ) app.use('/graphql', graphqlHTTP( schema, graphiql: true )); app.listen(4000); I created a small repo and a small public npm package to demonstrate this repo-with-npm-dependency-on-graphql . This can be quite easily wor

Salinas, California

Image
City in California, United States Salinas, California City City of Salinas Main Street in downtown Salinas, 2006 Seal Wordmark Nickname(s):  "The Salad Bowl of the World" [1] Motto(s):  "Rich in Land, Rich in Values." [2] Location of Salinas, California Salinas, California Location in the United States Show map of California Salinas, California Salinas, California (the US) Show map of the US Coordinates: 36°40′40″N 121°39′20″W  /  36.67778°N 121.65556°W  / 36.67778; -121.65556 Coordinates: 36°40′40″N 121°39′20″W  /  36.67778°N 121.65556°W  / 36.67778; -121.65556 Country United States State California Region Northern California County Monterey Incorporated March 4, 1874 [3] Government  • Type Council-Manager  • Mayor Joe Gunter [4]  • State senator Anna Caballero (D) [5]  • Assemblymember Robert Rivas (D) [5]  • U. S. rep. Jimmy Panetta (D) [6] Area [7]  • City 23.65 sq mi (61.25 km 2 )  • Land 23.61 sq mi (61.15 km 2 )  • Water 0.04 sq mi (0.10 km 2 )  0.16