Skip to content

Instantly share code, notes, and snippets.

@PetersonDave
Created November 25, 2013 04:39
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save PetersonDave/7636456 to your computer and use it in GitHub Desktop.
Save PetersonDave/7636456 to your computer and use it in GitHub Desktop.
Define the routes - templateUrls are all Sitecore items! Sitecore now serves our views :)
function getRoutes() {
return [
{
url: '/profiles',
config: {
templateUrl: 'Views/allprofiles',
controller: 'allprofiles'
}
}, {
url: '/profiles/:profileId',
config: {
templateUrl: 'Views/modifyprofile',
controller: 'modifyprofile'
}
}, {
url: '/',
config: {
templateUrl: 'Views/main',
controller: 'main'
}
}];
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment