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
| 'use strict'; | |
| var lrSnippet = require('grunt-contrib-livereload/lib/utils').livereloadSnippet; | |
| var mountFolder = function (connect, dir) { | |
| return connect.static(require('path').resolve(dir)); | |
| }; | |
| module.exports = function (grunt) { | |
| // load all grunt tasks | |
| require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks); |
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
| Options +FollowSymLinks -MultiViews | |
| # Turn mod_rewrite on | |
| RewriteEngine On | |
| RewriteBase / | |
| ## hide .php extension | |
| # To externally redirect /dir/foo.php to /dir/foo | |
| RewriteCond %{THE_REQUEST} ^[A-Z]{3,}\s([^.]+)\.php [NC] | |
| RewriteRule ^ %1 [R,L,NC] |
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
| /** | |
| * WAY 1: ANGULARJS TUTORIAL | |
| */ | |
| // app.js | |
| var myApp = angular.module('myApp',[]); | |
| // controllers/greeting.js | |
| myApp.controller('GreetingCtrl', ['$scope', function($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
| var path = require('path'); | |
| var gulp = require('gulp'); | |
| var concat = require('gulp-concat'); | |
| var templateCache = require('gulp-angular-templatecache'); | |
| var addsrc = require('gulp-add-src'); | |
| var paths = { | |
| src: 'public/assets/src' | |
| }; |
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
| var gulp = require('gulp'); | |
| var path = require('path'); | |
| var paths = require('./paths'); | |
| var concat = require('gulp-concat'); | |
| var sourceMaps = require('gulp-sourcemaps'); | |
| var mainBowerFiles = require('main-bower-files'); | |
| var sourceOrdered = [ | |
| '!' + path.join(paths.scripts, 'bundle.js'), | |
| '!' + path.join(paths.scripts, 'vendor.js'), |
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
| var gulp = require('gulp'); | |
| var open = require('gulp-open'); | |
| var karma = require('karma').server; | |
| var protractor = require('gulp-protractor').protractor; | |
| var paths = require('./paths'); | |
| module.exports = { | |
| unit: function (done) { | |
| karma.start({ | |
| configFile: paths.tests.unit.config, |
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
| gulp.task('bundle:source', function () { | |
| return es.merge( | |
| gulp.src('src/scripts/**/*.html') | |
| .pipe(templateCache({ | |
| module: 'myModule', | |
| root: 'scripts' | |
| })), | |
| gulp.src([ | |
| 'src/scripts/app.js', |
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
| 'use strict'; | |
| angular.module('myAuthApp', [ | |
| 'ui.router' | |
| ]) | |
| .config(function ($urlRouterProvider, $stateProvider) { | |
| $stateProvider | |
| .state('login', { | |
| url: '/signin', | |
| templateUrl: 'src/views/auth/partials/login.html', |
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
| app/ | |
| ├── index.html | |
| └── src | |
| ├── app.js | |
| ├── bundle.js | |
| ├── common | |
| │ ├── auth.js | |
| │ ├── router.js | |
| │ └── storage.js | |
| ├── components |
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
| // gulpfile.js | |
| var gulp = require('gulp'); | |
| var requireDir = require('require-dir'); | |
| var tasks = requireDir('./tasks'); | |
| gulp.task('sass', tasks.sass); | |
| gulp.task('serve:dev', tasks.serve.dev); | |
| gulp.task('serve:dist', tasks.serve.dist); |
OlderNewer