Skip to content

Commit ad4bd30

Browse files
author
alexandercastillo
committed
folder structure updates
moving js to root, including test and gruntfile
1 parent b1e7c48 commit ad4bd30

File tree

9 files changed

+96
-20
lines changed

9 files changed

+96
-20
lines changed

.bowerrc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"directory": "components"
3+
}

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
node_modules
2+
components
3+
.DS_Store

Gruntfile.js

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
'use strict';
2+
3+
module.exports = function(grunt) {
4+
grunt.initConfig({
5+
pkg: grunt.file.readJSON('package.json'),
6+
7+
karma: {
8+
unit: {
9+
options: {
10+
files: [
11+
'node_modules/angular/angular.js',
12+
'node_modules/angular-mocks/angular-mocks.js',
13+
'node_modules/chai/chai.js',
14+
'angular-css.js',
15+
'test/spec.js'
16+
]
17+
},
18+
19+
frameworks: ['mocha'],
20+
21+
browsers: [
22+
'Chrome',
23+
'PhantomJS',
24+
'Firefox'
25+
],
26+
27+
singleRun: true
28+
}
29+
},
30+
31+
uglify: {
32+
options: {
33+
banner: '/*! <%= pkg.name %> <%= pkg.version %> | Copyright (c) <%= grunt.template.today("yyyy") %> DOOR3, Alex Castillo | MIT License */'
34+
},
35+
36+
build: {
37+
src: '<%= pkg.name %>.js',
38+
dest: '<%= pkg.name %>.min.js'
39+
}
40+
}
41+
});
42+
43+
grunt.loadNpmTasks('grunt-contrib-uglify');
44+
grunt.loadNpmTasks('grunt-karma');
45+
46+
grunt.registerTask('test', ['karma']);
47+
48+
grunt.registerTask('default', [
49+
'test',
50+
'uglify'
51+
]);
52+
};

src/angular-css.js renamed to angular-css.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
22
* CSS on-demand for AngularJS
3-
* @version v1.0.0
3+
* @version v1.0.3
44
* @author DOOR3, Alex Castillo
55
* @link http://door3.github.io/angular-css
66
* @license MIT License, http://www.opensource.org/licenses/MIT

angular-css.min.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

bower.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "angular-css",
3-
"main": "./src/angular-css.js",
4-
"version": "1.0.1",
3+
"main": "./angular-css.js",
4+
"version": "1.0.3",
55
"homepage": "http://door3.github.io/angular-css",
66
"authors": [
77
"Alex Castillo <[email protected]>"

package.json

Lines changed: 21 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
22
"name": "angular-css",
3-
"filename": "angular-css.min.js",
3+
"filename": "angular-css.js",
44
"description": "CSS on-demand for AngularJS",
5-
"version": "1.0.0",
5+
"version": "1.0.3",
66
"homepage": "http://door3.github.io/angular-css",
77
"repository": {
88
"type": "git",
@@ -11,20 +11,17 @@
1111
"npmName": "angular-css",
1212
"npmFileMap": [
1313
{
14-
"basePath": "/src/",
14+
"basePath": "/",
1515
"files": [
1616
"*.js"
1717
]
1818
}
1919
],
2020
"files": [
21+
"angular-css.js",
2122
"angular-css.min.js"
2223
],
23-
"author": {
24-
"name": "Alex Castillo",
25-
"url": "http://castillo.io",
26-
"email": "[email protected]"
27-
},
24+
"author": "Alex Castillo <[email protected]> (http://castillo.io)",
2825
"licenses": [
2926
{
3027
"type": "MIT",
@@ -40,9 +37,24 @@
4037
"autoupdate": {
4138
"source": "git",
4239
"target": "git://github.com/door3/angular-css",
43-
"basePath": "/src/",
40+
"basePath": "/",
4441
"files": [
4542
"*.js"
4643
]
44+
},
45+
"bugs": {
46+
"url": "https://github.com/door3/angular-css/issues"
47+
},
48+
"main": "angular-css.js",
49+
"license": "MIT",
50+
"scripts": {
51+
"test": "grunt test"
52+
},
53+
"devDependencies": {
54+
"grunt": "~0.4.1",
55+
"grunt-contrib-uglify": "~0.2.4",
56+
"grunt-karma": "~0.7.1",
57+
"karma-mocha": "~0.1.0",
58+
"grunt-cli": "~0.1.11"
4759
}
4860
}

src/angular-css.min.js

Lines changed: 0 additions & 8 deletions
This file was deleted.

test/spec.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
'use strict';
2+
3+
describe('door3.css', function () {
4+
5+
var expect = chai.expect;
6+
7+
beforeEach(module('door3.css'));
8+
9+
it('should contain $css service', inject (function($css) {
10+
expect($css).not.to.equal(null);
11+
}));
12+
13+
});

0 commit comments

Comments
 (0)