• Recipes with Angular.js

  • Menu
  • Search
  • Home
  • Introduction
  • Controllers
  • Directives
  • Filters
  • Using Forms
  • Consuming External Services
  • Urls Routing and Partials
    • Client-Side Routing with Hashbang URLs
    • Using Regular URLs with the HTML5 History API
    • Using Route Location to Implement a Navigation Menu
    • Listening on Route Changes to Implement a Login Mechanism
  • Common User Interface Patterns
  • Backend Integration with Ruby on Rails
  • Backend Integration with Node Express

URLs, Routing and Partials

The $location service in Angular.js parses the current browser URL and makes it available to your application. Changes in either the browser address bar or the $location service will be kept in sync.

Depending on the configuration, the $location service behaves differently and has different requirements for your application. We will first look into client-side routing with hashbang URLs since it is the default mode, and then later, look at the new HTML5-based routing.

Table of Contents

  1. URLs, Routing and Partials
  2. Client-Side Routing with Hashbang URLs
  3. Using Regular URLs with the HTML5 History API
  4. Using Route Location to Implement a Navigation Menu
  5. Listening on Route Changes to Implement a Login Mechanism
  • Share
vue.js component pattern book

Checkout my new project:

Vue.js Component Patterns Book

The goal of this course is to teach you the fundamentals to make Vue.js components that are simpler, more flexible and most of all fun to build and use!

Maintained by Frederik Dietz

All content licensed with Creative Commons