Tag: express
-
Localhost Connection Interruption Issue with Express Server and Firebase Functions
0 I want my phone, on the same Wi-Fi as my computer, to access my computer’s Express server at its localhost. In the past, I used ngrok or a proxy on my web server to achieve this, but it was complex and costly. Now, I’ve set up a direct proxy on my Express server to…
-
Passing request parameter into middleware which uses ‘createHandler’ function of ‘graphql-http’
0 I have created an express server which uses GraphQL for handling requests over HTTP. Among others, the express server has the two middlewares below. app.use(authenticate); app.use(‘/graphql’, createHandler({ schema })); The authenticate middleware invokes a function which has req, res and next as parameters and in certain conditions assigns a value to req.user. How can…
-
Passing request parameter into middleware using createHandler function of graphql-http
0 I have created an express server which uses GraphQL for handling requests over HTTP. Among others, the express server has the two middlewares below. app.use(authenticate); app.use(‘/graphql’, createHandler({ schema })); The authenticate middleware invokes a function which has req, res and next as parameters and in certain conditions assigns a value to req.user. How can…
-
Issue with GraphQL and TypeORM – Fetching Products with Images
0 I’m working on a GraphQL API using TypeORM as the ORM to interact with my PostgreSQL database. I’m currently facing an issue when trying to fetch products along with their associated images using GraphQL queries. I have two tables: products and images. Each product can have multiple images associated with it. The images table…
-
Can’t import the named export XXXX from non EcmaScript module (only default export is available)
30 I have a client-server setup, in which the client(create-react-app) runs on localhost:3000 and the server is an express server which is built on node and I’m attempting to build graphql schema-resolvers setup. I’m able to import .graphql files on the server, however, on the client side, I’m using this setup by graphql-tools. When I’m…
-
Issue with GraphQL and TypeORM – Fetching Products with Images
0 Certainly, here’s a possible Stack Overflow question you could use to get help with your issue: Title: Issue with GraphQL and TypeORM – Fetching Products with Images Description: I’m working on a GraphQL API using TypeORM as the ORM to interact with my PostgreSQL database. I’m currently facing an issue when trying to fetch…
-
Error: “Query.getAllBooks” was defined in resolvers, but not in schema
0 I’m currently working on a small Nest.js application where I want to create a GraphQL query to retrieve an array of books. However, I’m encountering an issue where I’m not getting the expected response. I’ve provided the relevant code snippets below. Can someone please help me identify what I might be doing wrong? src/books/books.dto.ts…
-
make graphql mutation return multiple types
0 i’m working on creating mutations for a project i’m working on but stuck on the resolver returns, i won’t to handle the errors while i’m at it as well by sending back messages for notifications to make it user friendly, but let’s say my mutation is UPDATE_USER and it should also return the updated…
-
TypeORM Entity Association Returns Null for Related Fields in GraphQL Nexus Schema
0 I’m currently building a GraphQL API using TypeORM and Nexus Schema. I’ve defined several entities with associations between them, such as Product, Brand, and User. The problem I’m facing is that when I query the Product entity using GraphQL, the related fields like category_id and brand_id are returning null values even though there is…
-
How to upload single / multiple images using Apollo-server-express and mongodb?
0 Image upload using Apollo server and mongodb database . If any body has solution or reference, please let me know. Thank you node.js mongodb express graphql apollo-server Share Follow asked Jul 17 at 13:48 DigenDigen 5999 bronze badges Add a comment | 1 Answer 1 Sorted by: Reset to default Highest score (default) Trending…