koajs / bodyparser

Koa body parsing middleware
MIT License
1.3k stars 116 forks source link

Not working with fusionjs #114

Closed mrmuhammadali closed 5 years ago

mrmuhammadali commented 5 years ago

Whenever I import koa-bodyparser it gives me following error in console. I'm using Uber's Fusionjs app.

screenshot 2018-11-21 at 10 08 57 pm
mrmuhammadali commented 5 years ago

This was due to tree-shaking issues with koa-bodyparser in an isomorphic application. One thing I tried is to enable the assumeNoImportSideEffects field inside of .fusionrc.js and it solved the issue. More information: https://fusionjs.com/api/fusion-cli/docs/fusionrc#assumenoimportsideeffects