Tag Archives: angular

Home / angular
76 Posts

Angular’s routing does a lot for us. Whether you’re using ui-router or ngRouter, you get a many powerful mechanisms to determine when your state has changed. There are times, though, that I want a “global state.”

What do I mean by global state?

More Link

Yes, yes, you’ve probably seen posts regarding creating a modal dialog service before. I’ve been using one for a bit and wanted to share my spin on this concept.

Angular’s ui-bootstrap directives provide a lot of functionality out of the box. Having the $modal providers really make it easy to manage dialogs. While it is easy to create your own service that can create simple OK/Cancel requests, it is also pretty straight forward to create modals that let you pass data back and forth to your calling controller.

More Link

In .NET when I’m dealing with WebAPI controllers, I like to secure them.  Typically, this is done with an [Authorize] attribute on the controller or the controller’s actions.

One problem that arises with .NET, though, is that a user’s auth token/cookie could be expired because they are inactive for a set amount of time.  Imagine that you’ve written a shiny new SPA-type web app and is SOA driven.  When the user resumes accessing your site, all of the API end-points will fail until the user logs back in.

More Link

I’m not one to clutch strongly to ideals, or entrench myself in unrelenting philosophies, but I am a creature of habit.  Most of my web applications over the past year have been Angular based and I have certain proclivities to particular structures in my applications.  My IDE of choice has been Visual Studio 2013, so I take advantage of it and .NET to serve up my base structure.

In dealing with VS2013/.NET, there are some base mechanisms of which I take advantage.  The ones I’d like to discuss are .NET bundling and Nuget.

More Link

Request interceptors in Angular are extremely handy.  They are essentially like jQuery’s global settings for $.ajax requests.  There are some not-so-subtle differences and framework tie-ins as well.

One of the simplest things I like to use request interceptors is for displaying an activity indicator.  My favorite activity indicator is spin.js as well.

More Link

I’ve been asked a few times why would you use the ui-Router instead of the built-in ngRoute.

I, not so succinctly, explained that it was because it allows for states and nested/hierarchical views.

More Link