Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
N
next.js
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Alex
next.js
Commits
dd3bb73d
Commit
dd3bb73d
authored
Jan 27, 2020
by
Danny Tatom
Committed by
Tim Neutkens
Jan 27, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update typo in typescript docs (#10276)
parent
c71694e2
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
typescript.md
docs/basic-features/typescript.md
+2
-2
No files found.
docs/basic-features/typescript.md
View file @
dd3bb73d
...
@@ -101,7 +101,7 @@ The following is an example of how to use the built-in types for API routes:
...
@@ -101,7 +101,7 @@ The following is an example of how to use the built-in types for API routes:
import
{
NextApiRequest
,
NextApiResponse
}
from
'next'
import
{
NextApiRequest
,
NextApiResponse
}
from
'next'
export
default
(
req
:
NextApiRequest
,
res
:
NextApiResponse
)
=>
{
export
default
(
req
:
NextApiRequest
,
res
:
NextApiResponse
)
=>
{
res
.
status
(
200
).
json
({
name
:
'J
ho
n Doe'
})
res
.
status
(
200
).
json
({
name
:
'J
oh
n Doe'
})
}
}
```
```
...
@@ -115,6 +115,6 @@ type Data = {
...
@@ -115,6 +115,6 @@ type Data = {
}
}
export
default
(
req
:
NextApiRequest
,
res
:
NextApiResponse
<
Data
>
)
=>
{
export
default
(
req
:
NextApiRequest
,
res
:
NextApiResponse
<
Data
>
)
=>
{
res
.
status
(
200
).
json
({
name
:
'J
ho
n Doe'
})
res
.
status
(
200
).
json
({
name
:
'J
oh
n Doe'
})
}
}
```
```
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment