Giter Club home page Giter Club logo

fastify-prisma-rest-api's Issues

postman collection.json

The postman.json file in the repo is for the environment.
Great tutorial looking forward to learning something new. Thank you.

addSchema erroe

I am getting TypeError: schema_1.default is not iterable error during schema addition.

for (const schema of [...productSchemas]) {
server.addSchema(schema);
}

Being a newbie not sure how to default export the schema file. Please help. I am doing something stupidly wrong.

FastifyError: Schema with id 'Schema' already declared!

hi,
First of all, the video is great I have learned a lot, thank you so much.

Looks like there is something has changed in fastify, i have followed your tutorial video everything went great up until I add product.schema to addschema() function in fastify app.ts file. I am getting the below error.

(node:27437) [FST_MODULE_DEP_FASTIFY-JWT] FastifyWarning.fastify-jwt: fastify-jwt has been deprecated. Use @fastify/[email protected] instead. (Use node --trace-warnings ... to show where the warning was created) FastifyError: Schema with id 'Schema' already declared! at Schemas.add (/home/mohan/Programming/fastify/tutorial/node_modules/fastify/lib/schemas.js:33:11) at SchemaController.add (/home/mohan/Programming/fastify/tutorial/node_modules/fastify/lib/schema-controller.js:62:30) at Object.addSchema (/home/mohan/Programming/fastify/tutorial/node_modules/fastify/fastify.js:606:29) at /home/mohan/Programming/fastify/tutorial/src/app.ts:39:16 at Generator.next (<anonymous>) at /home/mohan/Programming/fastify/tutorial/src/app.ts:8:71 at new Promise (<anonymous>) at __awaiter (/home/mohan/Programming/fastify/tutorial/src/app.ts:4:12) at main (/home/mohan/Programming/fastify/tutorial/src/app.ts:41:12) at Object.<anonymous> (/home/mohan/Programming/fastify/tutorial/src/app.ts:56:1) [ERROR] 21:10:41 FastifyError: Schema with id 'Schema' already declared! Child got SIGTERM, exiting.

Error is because of that id, see below console.log of schema

Screenshot_20221020_212101

I have no idea how to solve it, I thought I made some error but the same problem persist even when I clone and run this project. please have a look

Implementation with @fastify/swagger

HI anyone know how to use this with new package @fastify/swagger, I saw it uses @fastify/swagger-ui as well.
Not sure how to make it work with the withRefResolver from zod

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.