-
Notifications
You must be signed in to change notification settings - Fork 785
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add line highlighting in custom model examples #5097
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
This PR changes the following pages (Vercel Preview Deploy links): Changed Vercel links
(Note that links will only be valid after Vercel preview deploy succeeded) |
This PR probably requires the following redirects to be added to vercel.json:
|
@@ -173,7 +173,7 @@ You can "rename" fields and models that are used in Prisma Client by mapping the | |||
|
|||
_After_ you introspected your database with `prisma db pull`, you can manually adjust the resulting Prisma schema as follows: | |||
|
|||
```prisma | |||
```prisma highlight=1-2;edit|4;edit|5-6;add|9;edit|12-13;edit|16;add|19-20;edit|25-26;edit|27-28;add|31-32;edit|35;edit|36-27;add|40-41;edit|44-45;edit|46-47;add |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code snippet is too chaotic, and hard to follow the changes. I would suggest either:
- Using tabs — one tab containing the updates and the other one for the final schema (no highlights)
- A combo of a comment (right above the relation field) and highlight for the section with the
@@map("")
attribute function - Using a simpler (our standard) schema with the Post & User models
I'm not sure this PR is an improvement, it's very noisy indeed. At this point, I'd probably prefer not using any highlights and keep the code snippet plain. If you still feel strongly about line highlighting here, let's discuss on Slack how to best go about this 🙏 |
Fixes #3815