Skip to content

Commit f0e55e1

Browse files
authored
Prisma の接続方法を修正 (#844)
1 parent 8f99d94 commit f0e55e1

File tree

5 files changed

+10
-6
lines changed

5 files changed

+10
-6
lines changed

docs/3-web-servers/03-node-js/index.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@ xcode-select --install
2222

2323
<video src={installCommandLineDeveloperToolsVideo} controls />
2424

25-
まずは、[nvmのウェブサイトの`Install & Update Script`セクション](https://github.com/nvm-sh/nvm#install--update-script)に書かれているスクリプトを実行しましょう。2024年9月現在では、次の通りです。
25+
まずは、[nvmのウェブサイトの`Install & Update Script`セクション](https://github.com/nvm-sh/nvm#install--update-script)に書かれているスクリプトを実行しましょう。2025年4月現在では、次の通りです。
2626

2727
```shell
28-
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash
28+
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bash
2929
```
3030

3131
続いて、ターミナルアプリケーションを再起動してから、nvmのインストールが成功していることを確認するため、次のコマンドを実行します。
@@ -38,7 +38,7 @@ nvm -v
3838

3939
```shell
4040
$ nvm -v
41-
0.40.1
41+
0.40.3
4242
```
4343

4444
さらに、次のコマンドを実行して、Node.jsをインストールします。
@@ -57,7 +57,7 @@ node -v
5757

5858
```shell
5959
$ node -v
60-
v20.17.0
60+
v22.15.0
6161
```
6262

6363
<Tabs groupId="os">
-1010 KB
Binary file not shown.

docs/3-web-servers/08-database/index.mdx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,14 +116,18 @@ npx prisma init
116116

117117
<video src={copySecretValuesVideo} controls muted />
118118

119-
`prisma/schema.prisma`ファイルを、次のように編集し、データベースのテーブルとカラムを定義します
119+
`prisma/schema.prisma`ファイルを、次のように追記し、`ToDo`テーブルとそのカラムを定義します
120120

121121
```javascript
122122
// This is your Prisma schema file,
123123
// learn more about it in the docs: https://pris.ly/d/prisma-schema
124124

125+
// Looking for ways to speed up your queries, or scale easily with your serverless or edge functions?
126+
// Try Prisma Accelerate: https://pris.ly/cli/accelerate-init
127+
125128
generator client {
126129
provider = "prisma-client-js"
130+
output = "../generated/prisma"
127131
}
128132

129133
datasource db {
@@ -143,7 +147,7 @@ model Todo {
143147
npx prisma db push
144148
```
145149

146-
コマンドを実行しましょう。すると、データベースに`schema.prisma`に書かれた通りのテーブルとカラムが作成されるので、DBeaverで確認してみてください。接続を一旦切断し、再接続する必要があります。また、このとき、後述する`@prisma/client`パッケージが自動的にインストールされます。
150+
コマンドを実行しましょう。すると、データベースに`schema.prisma`に書かれた通りのテーブルとカラムが作成されるので、Supabaseから確認してみてください。また、このとき、後述する`@prisma/client`パッケージが自動的にインストールされます。
147151

148152
<video src={prismaDbPushVideo} controls />
149153

-1.23 MB
Binary file not shown.
-511 KB
Binary file not shown.

0 commit comments

Comments
 (0)