You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using config/server.js and the apiProxy feature to stub out API's it can be useful to put those stubs in a separate directory/file to avoid clogging up server.js. When a require statement fails to locate a path, due to a typo or non-existent file, api stubbing and proxying fails silently and express starts throwing 404's.
I'm thinking this may have something to do with watch_r being used to monitor the server.js file for changes and re-evaluate it but haven't dug into why this is.
We should see if we can make things explode loudly when requires fail in this manner.
When using
config/server.js
and the apiProxy feature to stub out API's it can be useful to put those stubs in a separate directory/file to avoid clogging upserver.js
. When arequire
statement fails to locate a path, due to a typo or non-existent file, api stubbing and proxying fails silently and express starts throwing 404's.I'm thinking this may have something to do with watch_r being used to monitor the
server.js
file for changes and re-evaluate it but haven't dug into why this is.We should see if we can make things explode loudly when requires fail in this manner.
ie:
The text was updated successfully, but these errors were encountered: