This project is a sample project for web application development with ASP.NET MVC5. It consists of the following:
- ASP.NET MVC5
- OWIN
- Grunt
-
Fork or clone this repository
-
Open a powershell window and make sure you are in the
Sample
folder of the project -
Type in the following command:
npm install
This command will restore all the required packages for this project.
-
Open project with Visual Studio
-
Build & Run
-
Open
Task Runner Explorer
window in Visual StudioTip: If you cannot find it type in
Task Runner Explorer
into the Quick Launch on the upper right corner -
You should see the task runner explorer open up
-
Double click on
watch:scripts
What's happening??
Basically, watch is a grunt task that keeps looking out for file changes so whenever you make change to any of the typescript
(*.ts)
files it will compile those files for you. -
Navigate to
\Scripts\ng-controllers\home\index-controllers.ts
and make any change you should see it compile -
That's it!!
-
Delete all of the
js
files andjs.map
files inScripts
folder -
Compile all typescript files, which will result in
*.js
in separate folders -
Uglify and bundle all
*.js
files into one file calledbundle.js
Note bundle.js
file is not included in the project