You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/components/schema/api/copy/best-practices.md
+6-6
Original file line number
Diff line number
Diff line change
@@ -38,17 +38,17 @@ code chunks. The most common approach is to break up types into files, either on
38
38
However you end up structuring your files, they ultimately all need to be imported and passed to the `makeSchema` function, and keeping a consistent approach to file naming makes it simpler
39
39
40
40
```ts
41
-
import*asuserTypesfrom"./schema/user";
42
-
import*aspostTypesfrom"./schema/post";
43
-
import*ascommentTypesfrom"./schema/comment";
41
+
import*asuserTypesfrom'./schema/user'
42
+
import*aspostTypesfrom'./schema/post'
43
+
import*ascommentTypesfrom'./schema/comment'
44
44
```
45
45
46
46
You could also consolidate this in an `index.js` or similar export file:
Copy file name to clipboardExpand all lines: docs/components/schema/api/copy/ecosystem-plugins.md
+2-2
Original file line number
Diff line number
Diff line change
@@ -11,12 +11,12 @@ sidebar_label: nexus-prisma
11
11
`nexus-prisma` is for bridging [Prisma](https://www.prisma.io) and [Nexus](https://nexus.js.org). It extends the Nexus DSL `t` with `.model` and `.crud` making it easy to project Prisma models and expose operations against them in your GraphQL API. Resolvers are dynamically created for you removing the need for traditional ORMs/query builders like TypeORM, Sequelize, or Knex. Out-of-box features include pagination, filtering, and ordering. When you do need to drop down into custom resolvers a [`Photon`](https://photonjs.prisma.io) instance on `ctx` will be ready to serve you, the same great tool `nexus-prisma` itself bulids upon.
12
12
13
13
```ts
14
-
import { nexusPrismaPlugin } from"nexus-prisma";
14
+
import { nexusPrismaPlugin } from'nexus-prisma'
15
15
16
16
makeSchema({
17
17
// ...
18
18
plugin: [nexusPrismaPlugin()],
19
-
});
19
+
})
20
20
```
21
21
22
22
If you are still using `nexus-prisma@0.3` / Prisma 1 you can find the old docs [here](https://github.com/prisma-labs/nexus/blob/8cf2d6b3e22a9dec1f7c23f384bf33b7be5a25cc/docs/database-access-with-prisma-v2.md).
0 commit comments