Conversation
|
This pull request is automatically deployed with Now. |
|
Related issue: stelligent/dromedary-serverless#3 The solution seems to be adding the |
|
Are you trying to use |
|
With Now 2.0 builders, the entry point to the builder can be TypeScript and it will perform the compilation and actually bundle all the code into a lamda. The problem I’m running into is that the bundle does not include the CLI so I can’t spawn a child process to invoke npm install. So now I'm attempting to use the npm API directly so it gets included in the bundle, but ran into a different problem with ncc. |
|
I think you can try using Maybe like this https://github.com/r0mflip/actions-deploy-zeit/blob/master/now.json#L6 and https://github.com/r0mflip/actions-deploy-zeit/blob/master/package.json#L7 |
|
@r0mflip If you think you can fix it, feel free to create a PR 😁 I’m pretty certain I can’t use a static builder because this is not a static website. At best, I could use the node-server builder but I would like to wait for feedback on this ncc bug: vercel/ncc#275 |
|
@styfle Yeah, you are right, I'am wrong about that. Can't build a traditional server on zeit right? |
|
@r0mflip You can build a traditional server. See https://github.com/styfle/react-server-example-tsx for an example that was just upgrade to Now 2.0 The thing to remember is that "traditional" servers have the assumption that they can take as long as necessary to boot because it only happens once. But serverless favors many smaller, faster booting microservices so it can be scaled out on-the-fly as traffic increases (or scaled down when traffic decreases). Now 2.0 pushes you (the developer) towards this serverless architecture. |
|
Each route becomes an isolated microservice right. |
|
Ideally, yes |
|
LET'S DO THIS! |
This is my first attempt to get Package Phobia running on Now v2