Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit86a9c7d

Browse files
committed
Stable Version 2.2.3.
Converted to ES6.
1 parent05c4e7a commit86a9c7d

File tree

8 files changed

+1020
-899
lines changed

8 files changed

+1020
-899
lines changed

‎.jshintrc‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"node":false,
33
"browser":true,
4-
"es5":true,
54
"esnext":true,
65
"bitwise":true,
76
"camelcase":true,

‎CHANGELOG.md‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,12 @@
1+
#####2.2.3 - 08 March 2015
2+
3+
######Other
4+
- Converted to ES6, using Babel.js to transpile to ES5.
5+
16
#####2.2.2 - 04 March 2015
27

38
######Backwards compatible bug fixes
4-
-#312 - UMDifying js-data-angular
9+
-#312 - UMDifying js-data-angular
510
-#313 - DSHttpAdapter#find/create/update/destroy do not call queryTransform
611

712
#####2.2.1 - 25 February 2015

‎Gruntfile.js‎

Lines changed: 46 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -13,18 +13,22 @@ module.exports = function (grunt) {
1313
});
1414
require('time-grunt')(grunt);
1515

16+
varwebpack=require('webpack');
1617
varpkg=grunt.file.readJSON('package.json');
18+
varbanner='js-data-angular\n'+
19+
'@version '+pkg.version+' - Homepage <https://www.js-data.io/docs/js-data-angular/>\n'+
20+
'@author Jason Dobry <jason.dobry@gmail.com>\n'+
21+
'@copyright (c) 2014-2015 Jason Dobry \n'+
22+
'@license MIT <https://github.com/js-data/js-data-angular/blob/master/LICENSE>\n'+
23+
'\n'+
24+
'@overview Angular wrapper for js-data.';
1725

1826
// Project configuration.
1927
grunt.initConfig({
2028
pkg:pkg,
2129
clean:{
2230
dist:['dist/']
2331
},
24-
jshint:{
25-
all:['Gruntfile.js','src/**/*.js'],
26-
jshintrc:'.jshintrc'
27-
},
2832
watch:{
2933
dist:{
3034
files:['src/**/*.js'],
@@ -36,10 +40,10 @@ module.exports = function (grunt) {
3640
options:{
3741
sourceMap:true,
3842
sourceMapName:'dist/js-data-angular.min.map',
39-
banner:'/**\n'+
43+
banner:'/*!\n'+
44+
'* js-data-angular\n'+
45+
'* @version <%= pkg.version %> - Homepage <https://www.js-data.io/docs/js-data-angular/>\n'+
4046
'* @author Jason Dobry <jason.dobry@gmail.com>\n'+
41-
'* @file js-data-angular.min.js\n'+
42-
'* @version <%= pkg.version %> - Homepage <https://www.js-data.io/js-data-angular/>\n'+
4347
'* @copyright (c) 2014-2015 Jason Dobry <https://github.com/jmdobry/>\n'+
4448
'* @license MIT <https://github.com/js-data/js-data-angular/blob/master/LICENSE>\n'+
4549
'*\n'+
@@ -80,6 +84,40 @@ module.exports = function (grunt) {
8084
options:{
8185
coverage_dir:'coverage'
8286
}
87+
},
88+
webpack:{
89+
dist:{
90+
entry:'./src/index.js',
91+
output:{
92+
filename:'./dist/js-data-angular.js',
93+
libraryTarget:'umd',
94+
library:'jsDataAngularModuleName'
95+
},
96+
externals:{
97+
'js-data':{
98+
amd:'js-data',
99+
commonjs:'js-data',
100+
commonjs2:'js-data',
101+
root:'JSData'
102+
},
103+
'angular':'angular'
104+
},
105+
module:{
106+
loaders:[
107+
{test:/(src)(.+)\.js$/,exclude:/node_modules/,loader:'babel-loader?blacklist=useStrict'}
108+
],
109+
preLoaders:[
110+
{
111+
test:/(src)(.+)\.js$|(test)(.+)\.js$/,// include .js files
112+
exclude:/node_modules/,// exclude any and all files in the node_modules folder
113+
loader:"jshint-loader?failOnHint=true"
114+
}
115+
]
116+
},
117+
plugins:[
118+
newwebpack.BannerPlugin(banner)
119+
]
120+
}
83121
}
84122
});
85123

@@ -91,28 +129,9 @@ module.exports = function (grunt) {
91129
grunt.file.write(filePath,file);
92130
});
93131

94-
grunt.registerTask('banner',function(){
95-
varfile=grunt.file.read('./src/index.js');
96-
97-
varbanner='/**\n'+
98-
'* @author Jason Dobry <jason.dobry@gmail.com>\n'+
99-
'* @file js-data-angular.js\n'+
100-
'* @version '+pkg.version+' - Homepage <http://www.js-data.io/docs/js-data-angular/>\n'+
101-
'* @copyright (c) 2014-2015 Jason Dobry <https://github.com/jmdobry/>\n'+
102-
'* @license MIT <https://github.com/js-data/js-data-angular/blob/master/LICENSE>\n'+
103-
'*\n'+
104-
'* @overview Angular wrapper for js-data.js.\n'+
105-
'*/\n';
106-
107-
file=banner+file;
108-
109-
grunt.file.write('./dist/js-data-angular.js',file);
110-
});
111-
112132
grunt.registerTask('build',[
113133
'clean',
114-
'jshint',
115-
'banner',
134+
'webpack',
116135
'uglify'
117136
]);
118137
grunt.registerTask('go',['build','watch:dist']);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp