Skip to content

nuxtjs3 - rest-nuxtjs example #5107

Open
@schalkneethling

Description

@schalkneethling

I have a general question about the Nuxtjs Prisma repo:
https://github.com/prisma/prisma-examples/tree/latest/typescript/rest-nuxtjs

Although I can see that the example repository uses Nuxt3 ("nuxt": "3.6.5" at the time of writing), the API methods are defined in server/routes. I am not saying that this is incorrect, but according to the Nextjs docs (https://nuxt.com/docs/guide/directory-structure/server#server-directory), it might be more nuxi 😄 if the API lives inside server/api.

What do you all think? Thanks!

Update: The main difference is that when in routes, the route will not have /api prepended.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions