add: built in api support is added, as an example GET /api/health-check endpoint is added #113

Merged
mehmetsefabalik merged 7 commits from master into master 2020-08-04 09:08:48 -04:00
mehmetsefabalik commented 2020-07-23 13:38:30 -04:00 (Migrated from github.com)
No description provided.
omeraplak commented 2020-07-27 05:46:24 -04:00 (Migrated from github.com)

Hi @mehmetsefabalik ,
Could you add feature usage documentation?

Hi @mehmetsefabalik , Could you add feature usage documentation?
omeraplak (Migrated from github.com) requested changes 2020-07-27 05:48:49 -04:00
@ -0,0 +1,5 @@
import { NextApiRequest, NextApiResponse } from "next";
omeraplak (Migrated from github.com) commented 2020-07-27 05:48:45 -04:00

Could you add return typedef?

Could you add return typedef?
mehmetsefabalik commented 2020-07-31 16:10:29 -04:00 (Migrated from github.com)

Hi @mehmetsefabalik ,
Could you add feature usage documentation?

this is the feature of nextjs, it is well documented in nextjs docs. So the user of this boilerplate is supposed to read this feature from nextjs docs.

> Hi @mehmetsefabalik , > Could you add feature usage documentation? this is the feature of nextjs, it is well documented in nextjs docs. So the user of this boilerplate is supposed to read this feature from nextjs docs.
mehmetsefabalik (Migrated from github.com) reviewed 2020-07-31 16:13:33 -04:00
@ -0,0 +1,5 @@
import { NextApiRequest, NextApiResponse } from "next";
mehmetsefabalik (Migrated from github.com) commented 2020-07-31 16:13:33 -04:00

return typedef is any, I added it

return typedef is any, I added it
BatuhanW (Migrated from github.com) reviewed 2020-08-03 06:24:16 -04:00
@ -0,0 +1,5 @@
import { NextApiRequest, NextApiResponse } from "next";
BatuhanW (Migrated from github.com) commented 2020-08-03 06:24:16 -04:00

Let's make this 'OK', instead of 'working'.

Let's make this 'OK', instead of 'working'.
BatuhanW commented 2020-08-03 06:24:37 -04:00 (Migrated from github.com)

Hi @mehmetsefabalik ,
Could you add feature usage documentation?

this is the feature of nextjs, it is well documented in nextjs docs. So the user of this boilerplate is supposed to read this feature from nextjs docs.

We can still point to related documentation links 👍

> > Hi @mehmetsefabalik , > > Could you add feature usage documentation? > > this is the feature of nextjs, it is well documented in nextjs docs. So the user of this boilerplate is supposed to read this feature from nextjs docs. We can still point to related documentation links 👍
mehmetsefabalik (Migrated from github.com) reviewed 2020-08-03 11:20:44 -04:00
@ -0,0 +1,5 @@
import { NextApiRequest, NextApiResponse } from "next";
mehmetsefabalik (Migrated from github.com) commented 2020-08-03 11:20:43 -04:00

done

done
mehmetsefabalik commented 2020-08-03 11:31:05 -04:00 (Migrated from github.com)

Hi @mehmetsefabalik ,
Could you add feature usage documentation?

this is the feature of nextjs, it is well documented in nextjs docs. So the user of this boilerplate is supposed to read this feature from nextjs docs.

We can still point to related documentation links 👍

done

> > > Hi @mehmetsefabalik , > > > Could you add feature usage documentation? > > > > > > this is the feature of nextjs, it is well documented in nextjs docs. So the user of this boilerplate is supposed to read this feature from nextjs docs. > > We can still point to related documentation links 👍 done
BatuhanW (Migrated from github.com) approved these changes 2020-08-03 12:46:06 -04:00
aliemir commented 2020-08-04 03:03:51 -04:00 (Migrated from github.com)

Hi @mehmetsefabalik, thank you for your contribution. I noticed that only get requests are handled by the custom server side. Since you are adding the api routes support, can you check the server files to handle other http methods?

server/index.ts#L34

I'm guessing changing this line from .get() to .all() might be enough.

Hi @mehmetsefabalik, thank you for your contribution. I noticed that only get requests are handled by the custom server side. Since you are adding the api routes support, can you check the server files to handle other http methods? [server/index.ts#L34](https://github.com/pankod/next-boilerplate/blob/master/server/index.ts#L34) I'm guessing changing this line from `.get()` to `.all()` might be enough.
mehmetsefabalik commented 2020-08-04 03:08:49 -04:00 (Migrated from github.com)

Hi @mehmetsefabalik, thank you for your contribution. I noticed that only get requests are handled by the custom server side. Since you are adding the api routes support, can you check the server files to handle other http methods?

server/index.ts#L34

I'm guessing changing this line from .get() to .all() might be enough.

done

> Hi @mehmetsefabalik, thank you for your contribution. I noticed that only get requests are handled by the custom server side. Since you are adding the api routes support, can you check the server files to handle other http methods? > > [server/index.ts#L34](https://github.com/pankod/next-boilerplate/blob/master/server/index.ts#L34) > > I'm guessing changing this line from `.get()` to `.all()` might be enough. done
omeraplak (Migrated from github.com) requested changes 2020-08-04 03:33:47 -04:00
@ -0,0 +1,5 @@
import { NextApiRequest, NextApiResponse } from "next";
omeraplak (Migrated from github.com) commented 2020-08-04 03:33:43 -04:00
export default (req: NextApiRequest, res: NextApiResponse): void => {
```suggestion export default (req: NextApiRequest, res: NextApiResponse): void => { ```
omeraplak (Migrated from github.com) approved these changes 2020-08-04 09:08:42 -04:00
omeraplak commented 2020-08-04 09:09:10 -04:00 (Migrated from github.com)

Thank you for contribution @mehmetsefabalik

Thank you for contribution @mehmetsefabalik
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
pankod/next-boilerplate!113
No description provided.