I try to build SPA application in Visual Studio 2013. I usually use single asp.net mvc project: web api for backend and some js logic for frontend. Asp.net mvc bundles successfully solve debug/release problem for me: in debug mode all js and css files loaded "as is" and in release mode minification and combination takes place.

Now i want to try something new: to separate backend and frontend completely by moving my frontend to another project. My backend will still use web api. But my frontend will use all cool modern stuff: node, gulp/grunt, bower, any SPA library etc... But i can not understand how to switch between debug and release mode in this separate frontend project without bundles. I have a number of js files with my business logic and css styles. In debug i want to load them "as is" and when i switch to release i want to combine all my js to one file and minify it. I believe that one possible solution is require.js but it seems like overkill for my small SPA application. How do you solve this problem in your projects?

Related posts

Recent Viewed