83a3903fc2
* HTTP methods docs and REST example * Update packages/next/README.md Co-Authored-By: Joe Haddad <timer150@gmail.com> * Update examples/api-routes-rest/README.md Co-Authored-By: Joe Haddad <timer150@gmail.com> * Fix standard
13 lines
178 B
JavaScript
13 lines
178 B
JavaScript
// Fake users data
|
|
const users = [
|
|
{
|
|
id: 1
|
|
},
|
|
{ id: 2 },
|
|
{ id: 3 }
|
|
]
|
|
|
|
export default (req, res) => {
|
|
// Get data from your database
|
|
res.status(200).json(users)
|
|
}
|