Skip to content
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

Docusaurus: fix image links #5772

Merged
merged 1 commit into from
Apr 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,10 @@ If you are storing your database connection string and other environment variabl
netlify open --admin
```
2. Click **Site settings**:
![Netlify admin UI](images/500-06-deploy-to-netlify-site-settings.png)
![Netlify admin UI](./images/500-06-deploy-to-netlify-site-settings.png)
3. Navigate to **Build & deploy** in the sidebar on the left and select **Environment**.
4. Click **Edit variables** and create a variable with the key `DATABASE_URL` and set its value to your database connection string.
![Netlify environment variables](images/500-07-deploy-to-netlify-environment-variables-settings.png)
![Netlify environment variables](./images/500-07-deploy-to-netlify-environment-variables-settings.png)
5. Click **Save**.

</details>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ For the **initial setup**:
1. You set up Prisma ORM by installing the Prisma ORM versions 2._x_ and later CLI and running `npx prisma init`.
1. You connect to your database and introspect it with `npx prisma db pull`.

![Prisma CLI introspection flow](images/prisma-cli-introspection-flow.png)
![Prisma CLI introspection flow](./images/prisma-cli-introspection-flow.png)

For **fixing the schema incompatibilities**:

Expand All @@ -100,7 +100,7 @@ For **fixing the schema incompatibilities**:
1. You run the `npx prisma-upgrade` command again.
1. The Upgrade CLI adjusts the Prisma schema (version 2._x_ and later) by adding missing attributes.

![Fixing the schema incompatibilities](images/fix-schema-incompatibilities.png)
![Fixing the schema incompatibilities](./images/fix-schema-incompatibilities.png)

Note that the Upgrade CLI is designed in a way that **you can stop and re-start the process at any time**. Once you ran a SQL command that was generated by the Upgrade CLI against your database, the SQL command will not show up the next time you invoke the Upgrade CLI. That way, you can gradually resolve all schema incompatibilities when it's convenient for you.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ Note that **you can start over at any time during the process** and go back from

In this illustration, the green area shows the first phase, the blue area shows the second phase. Note that you can optionally run `prisma db pull` in between the phases to update your Prisma ORM data model:

![Fixing the schema incompatibilities](images/fix-schema-incompatibilities.png)
![Fixing the schema incompatibilities](./images/fix-schema-incompatibilities.png)

To use the Upgrade CLI, you can either install it locally in your project, or invoke it once without installation using `npx` as done here:

Expand Down Expand Up @@ -590,7 +590,7 @@ https://pris.ly/d/schema-incompatibilities#enums-are-represented-as-text-in-data

Go ahead and run these statements against your database now.

![Altering columns to use ENUM with SQL](images/altering-columns-to-use-enum.png)
![Altering columns to use ENUM with SQL](./images/altering-columns-to-use-enum.png)

### 5.1.2. Add missing `DEFAULT` constraints to the database

Expand All @@ -608,7 +608,7 @@ https://pris.ly/d/schema-incompatibilities#default-values-arent-represented-in-d

You can now run these SQL statements against your database either using a command line client or a GUI like TablePlus:

![TablePlus GUI](images/TablePlus-GUI.png)
![TablePlus GUI](./images/TablePlus-GUI.png)

### 5.1.3. Fix columns with JSON data types

Expand All @@ -627,7 +627,7 @@ https://pris.ly/d/schema-incompatibilities#json-type-is-represented-as-text-in-d

You can now run these SQL statements against your database either using a command line client or a GUI like TablePlus:

![TablePlus GUI](images/fix-columns-with-json-data-types.png)
![TablePlus GUI](./images/fix-columns-with-json-data-types.png)

### 5.1.4. Replicate `@createdAt` behavior in Prisma ORM 2

Expand Down Expand Up @@ -756,7 +756,7 @@ For this fix, you'll need to run three SQL statements:
DROP TABLE `_PostToUser`;
```

![Fixing incorrect m-n relations with SQL](images/fix-incorrect-m-n-relations-sql.png)
![Fixing incorrect m-n relations with SQL](./images/fix-incorrect-m-n-relations-sql.png)

After these commands, the user ID values of the records from column `B` of the relation table are migrated to the new `authorId` column.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ Note that **you can start over at any time during the process** and go back from

In this illustration, the green area shows the first phase, the blue area shows the second phase. Note that you can optionally run `prisma db pull` in between the phases to update your Prisma ORM data model:

![Fixing the schema incompatibilities](images/fix-schema-incompatibilities.png)
![Fixing the schema incompatibilities](./images/fix-schema-incompatibilities.png)

To use the Upgrade CLI, you can either install it locally in your project, or invoke it once without installation using `npx` as done here:

Expand Down Expand Up @@ -591,7 +591,7 @@ https://pris.ly/d/schema-incompatibilities#enums-are-represented-as-text-in-data

Go ahead and run these statements against your database now.

![Altering columns to use ENUM with SQL](images/altering-columns-to-use-enum.png)
![Altering columns to use ENUM with SQL](./images/altering-columns-to-use-enum.png)

### 5.1.2. Add missing `DEFAULT` constraints to the database

Expand All @@ -609,7 +609,7 @@ https://pris.ly/d/schema-incompatibilities#default-values-arent-represented-in-d

You can now run these SQL statements against your database either using a command line client or a GUI like Postico:

![Adding missing `DEFAULT` constraints to columns](images/add-missing-default-constraints-to-columns.png)
![Adding missing `DEFAULT` constraints to columns](./images/add-missing-default-constraints-to-columns.png)

### 5.1.3. Fix columns with JSON data types

Expand All @@ -630,7 +630,7 @@ https://pris.ly/d/schema-incompatibilities#json-type-is-represented-as-text-in-d

You can now run these SQL statements against your database either using a command line client or a GUI like Postico:

![Adding missing `DEFAULT` constraints to columns](images/fix-columns-with-json-data-types.png)
![Adding missing `DEFAULT` constraints to columns](./images/fix-columns-with-json-data-types.png)


### 5.1.4. Replicate `@createdAt` behavior in Prisma ORM 2
Expand All @@ -648,7 +648,7 @@ https://pris.ly/d/schema-incompatibilities#createdat-isnt-represented-in-databas

You can now run these SQL statements against your database either using a command line client or a GUI like Postico:

![Running an SQL command to alter a column](images/run-sql-command-to-alter-column.png)
![Running an SQL command to alter a column](./images/run-sql-command-to-alter-column.png)

### 5.1.5. Fix 1-1 relations by adding `UNIQUE` constraints

Expand All @@ -665,7 +665,7 @@ https://pris.ly/d/schema-incompatibilities#inline-1-1-relations-are-recognized-a

You can now run these SQL statements against your database either using a command line client or a GUI like Postico:

![Running an SQL command to alter a column](images/run-sql-command-to-alter-column.png)
![Running an SQL command to alter a column](./images/run-sql-command-to-alter-column.png)

### 5.1.6. Fix mismatch of CUID length

Expand All @@ -688,7 +688,7 @@ https://pris.ly/d/schema-incompatibilities#mismatching-cuid-length

You can now run these SQL statements against your database either using a command line client or a GUI like Postico:

![Running an SQL command to alter a column](images/run-sql-command-to-alter-column.png)
![Running an SQL command to alter a column](./images/run-sql-command-to-alter-column.png)

### 5.1.7. Breaking changes detected

Expand Down Expand Up @@ -766,7 +766,7 @@ For this fix, you'll need to run three SQL statements:
DROP TABLE `_PostToUser`;
```

![Fixing incorrect m-n relations with SQL](images/fix-incorrect-m-n-relations-sql.png)
![Fixing incorrect m-n relations with SQL](./images/fix-incorrect-m-n-relations-sql.png)

After these commands, the user ID values of the records from column `B` of the relation table are migrated to the new `authorId` column.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ const User = objectType({

With this code in place, you can start exposing the _fields_ of the `User` model one by one. You can use your editor's autocompletion to save some typing. Inside the body of the `definition` function, type `t.model.` and then hit <kbd>CTRL</kbd>+<kbd>SPACE</kbd>. This will bring up the autocompletion and suggest all fields that are defined on the `User` model:

![Exposing Prisma model fields with t.model](images/expose-prisma-model-fields-with-t-model.png)
![Exposing Prisma model fields with t.model](./images/expose-prisma-model-fields-with-t-model.png)

Note that the `model` property on `t` is provided by the `nexus-plugin-prisma`. It leverages the type information from your Prisma schema and lets you expose your Prisma models via GraphQL.

Expand Down Expand Up @@ -461,7 +461,7 @@ To mirror the same behaviour with Nexus, you can use the `crud` property on the

Similar to `model`, this property is available because you're using the `nexus-prisma-plugin` which leverages type information from your Prisma models and auto-generates resolvers under the hood. The `crud` property also supports autocompletion, so you can explore all available queries in your editor again:

![Using t.crud to generate resolvers](images/use-t-crud-to-generate-resolvers.png)
![Using t.crud to generate resolvers](./images/use-t-crud-to-generate-resolvers.png)

##### Forwarding the query with the `nexus-prisma-plugin`

Expand Down Expand Up @@ -850,7 +850,7 @@ Similar to forwarding GraphQL queries, you can use the `crud` property on the `t

Similar to `model`, this property is available because you're using the `nexus-prisma-plugin` which leverages type information from your Prisma models and auto-generates resolvers under the hood. The `crud` property supports autocompletion when defining mutations as well, so you can explore all available operations in your editor again:

![Generating resolvers with t.crud](images/regenerate-resolvers-with-t-crud.png)
![Generating resolvers with t.crud](./images/regenerate-resolvers-with-t-crud.png)

##### Forwarding the mutation with the `nexus-prisma-plugin`

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ With Prisma ORM 2, there's no `prisma.graphql` file any more that you could impo

The easiest way to do so is by downloading the full GraphQL schema from the GraphQL Playground. To do so, open the **SCHEMA** tab and click the **DOWNLOAD** button in the top-right corner, then select **SDL**:

![Downloading the GraphQL schema with GraphQL Playground](images/download-graphql-schema.png)
![Downloading the GraphQL schema with GraphQL Playground](./images/download-graphql-schema.png)

Alternatively, you can use the `get-schema` command of the [GraphQL CLI](https://github.com/Urigo/graphql-cli) to download your full schema:

Expand Down
4 changes: 2 additions & 2 deletions docs/300-accelerate/580-local-development.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ This guide will explain how to use Prisma Accelerate client extension in a devel
## Using Prisma Accelerate client extension in development and production

<br />
<img src="images/accelerate-in-dev.png" alt="" />
<img src="img/accelerate/accelerate-in-dev.png" alt="" />

Accelerate does not work with a local database. However, in a development environment, you can still use Prisma Client with the Accelerate client extension. This setup will not provide Accelerate's connection pooling and caching features.

Expand Down Expand Up @@ -50,7 +50,7 @@ The following steps outline how to use Prisma ORM and Prisma Accelerate with a l

> The extended instance of Prisma Client will use the local database. Hence, Prisma Accelerate will not be used in your development environment to respond to your Prisma Client queries.

<img src="images/accelerate-in-prod.png" alt="" />
<img src="img/accelerate/accelerate-in-prod.png" alt="" />

If an Accelerate connection string is used as the `DATABASE_URL` environment variable, Prisma Client will route your queries through Accelerate.

Expand Down
Binary file added static/img/accelerate/accelerate-in-dev.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/img/accelerate/accelerate-in-prod.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.