calebmer / connect

10 stars 2 forks source link

API server production build #42

Closed calebmer closed 5 years ago

calebmer commented 5 years ago

A big missing part of #17 that I haven’t done yet is building the API server code for production. I have a development script with babel-watch but that’s not close to viable for production.

https://github.com/calebmer/connect/blob/7e7c02d9ea7b18cda9fbea956b94fcd013e8f889/api/server/package.json#L7

The tricky part here is api/server needs to import the built code from api/client. Which is where I gave up when I tried 😛

Let’s use Babel to compile TypeScript since that’s what we do everywhere else. (Including development mode.) I also want to make sure that async/await is not compiled so we can take advantage of V8’s performance work on async/await.