I am developing an express based web application and I started following the application skeleton built by express-generator.
Next, I added to my project webpack to bundle the client side assets.
In truth, I am in a dilemma between,
According to express-generator, it creates an
app.js file as the main entry and thus it looks a little bit strange to have an
app folder with same name of the entry point
webpack usage manual suggests a
Moreover, the Accepted Answer to the question Folder structure for a Node.js project, contradicts the previous point because it states:
/src contains all your server-side specific CoffeeScript files
So, I think that maybe
/src is not the better option to place front-end javscript files and according to the Accepted answer to the question Node.js project naming conventions for files & folders I would follow the proposed structure:
/bin - helper scripts
/lib - back-end express files
But is it ok to have a folder
/app and a file
app.js with same name? Furthermore,
/app is related with front-end and
app.js with back-end.