Getting Started with Ember JS
A while ago; we were asked to add new features into an existing Web Forms app; we decided its time to explore things outside of the comfort zone of the typical enterprise development team and do things the “modern-way” Thanks to One ASP.NET theme of .NET v4.5; we can have Web Api Controllers in the same Web Forms project / assembly! I will cover getting started with Ember JS in an ASP.NET Web Forms for this post. I will not be using Ember Data or Ember CLI. We will try to remain true to modern norms for web development; and this is why we are using NODE and not NUGET
- If you dont have the Node; Install Node.js; this is where cheese is these days!
- Optionally Install Power Commands for Visual Studio; it will give us option to open Command Prompt at our project folder using context menu
- Installing Node for Windows will create nodevars.bat that we can run to set Environment variables required for Node; next we need to install Bower; a npm module; think of installing Node modules as deploying assembly into global assembly cache and Bower for local assemblies; installing with -g install the node module globally (usually %appdata%\npm\node_modules)
- We will then initialize our project directory for Bower; this will create bower.json file; think of it as your web application C#/VB project file
- Next we will install Ember using Bower with dash-dash-save option; this will add ember dependency into the bower.json file
We can learn from Console; that it needs application template; lets add that and the “test” template to try out the transition, route for which we already have added