This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
http_path = "/public" | |
css_dir = "stylesheets" | |
sass_dir = "stylesheets" | |
iages_dir = "img" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
!function(ng){ | |
'use strict'; | |
var module = ng.module('foo.services', []); | |
(function($ng, $module) { | |
function Service($q) { | |
return { | |
bar: function(a,b,c){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
!function(ng){ | |
'use strict'; | |
var module = ng.module('app.controllers', []); | |
(function($ng, $module) { | |
function Controller($scope, requestContext) { | |
$scope.setWindowTitle = function (title) { | |
$scope.windowTitle = title; | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
describe('controller tests', function () { | |
var m, c; | |
beforeEach(function () { | |
m = angular.module('foo', []); | |
c = m.controller('TestCtrl', ['$scope', function ($scope) { | |
$scope.data = { foo: 'bar' }; | |
$scope.changeFoo = function () { | |
$scope.data.foo = 'baz'; | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
beforeEach(inject(function ($rootScope, $controller) { | |
scope = $rootScope.$new(); | |
ctrl = $controller("FooCtrl", {$scope: scope}); | |
})); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
angular.module('SweetMvcApp.services', []) | |
.factory('tokenService', function ($http, $q) { | |
function getToken() { | |
$http.defaults.useXDomain = true; | |
delete $http.defaults.headers.common['X-Requested-With']; | |
var deferred = $q.defer(), | |
ajxArgs = { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
angular.module('foo.directive', []) | |
.directive('restaurant', function(){ | |
return { | |
restrict: 'E', | |
template: '<li>Hello World</li>' | |
} | |
}); | |
angular.module('foo', ['foo.directive']); |