Skip to content

Commit 307511d

Browse files
committed
Merge pull request #1 from graphql/master
Merge latest changes from HEAD: 0.4.3 -> 0.4.18
2 parents e556526 + db0924a commit 307511d

File tree

126 files changed

+6969
-2721
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

126 files changed

+6969
-2721
lines changed

.eslintrc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@
174174
"no-unused-vars": [2, {"vars": "all", "args": "after-used"}],
175175
"no-use-before-define": 0,
176176
"no-useless-call": 2,
177-
"no-var": 0,
177+
"no-var": 2,
178178
"no-void": 2,
179179
"no-warning-comments": 0,
180180
"no-with": 2,
@@ -184,7 +184,7 @@
184184
"operator-assignment": [2, "always"],
185185
"operator-linebreak": [2, "after"],
186186
"padded-blocks": 0,
187-
"prefer-const": 0,
187+
"prefer-const": 2,
188188
"prefer-reflect": 0,
189189
"prefer-spread": 0,
190190
"quote-props": [2, "as-needed"],

.travis.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
language: node_js
22

33
node_js:
4+
- "stable"
5+
- "4"
46
- "iojs"
57
- "0.12"
68
- "0.10"

README.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,16 @@ This is a technical preview of the JavaScript reference implementation for
44
GraphQL, a query language created by Facebook for describing data requirements
55
on complex application data models.
66

7+
[![npm version](https://badge.fury.io/js/graphql.svg)](http://badge.fury.io/js/graphql)
78
[![Build Status](https://travis-ci.org/graphql/graphql-js.svg)](https://travis-ci.org/graphql/graphql-js)
89
[![Coverage Status](https://coveralls.io/repos/graphql/graphql-js/badge.svg?branch=master)](https://coveralls.io/r/graphql/graphql-js?branch=master)
9-
[![Public Slack Discussion](https://graphql-slack.herokuapp.com/badge.svg)](https://graphql-slack.herokuapp.com/)
10+
11+
See more complete documentation at http://graphql.org/ and
12+
http://graphql.org/docs/api-reference-graphql/.
13+
14+
For questions, ask [Stack Overflow](http://stackoverflow.com/questions/tagged/graphql).
15+
16+
For discussion, join [#graphql on Discord](http://join.reactiflux.com/).
1017

1118
## Technical Preview Contents
1219

package.json

Lines changed: 13 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
{
22
"name": "graphql",
3-
"version": "0.4.3",
3+
"version": "0.4.18",
44
"description": "A Query Language and Runtime which can target any service.",
55
"contributors": [
66
"Lee Byron <[email protected]> (http://leebyron.com/)",
77
"Nicholas Schrock <[email protected]>",
88
"Daniel Schafer <[email protected]>"
99
],
1010
"license": "BSD-3-Clause",
11+
"main": "index.js",
1112
"homepage": "https://github.com/graphql/graphql-js",
1213
"bugs": {
1314
"url": "https://github.com/graphql/graphql-js/issues"
@@ -19,19 +20,14 @@
1920
"options": {
2021
"mocha": "--require resources/mocha-bootload src/**/__tests__/**/*.js"
2122
},
22-
"babel": {
23-
"optional": [
24-
"runtime",
25-
"es7.asyncFunctions"
26-
]
27-
},
2823
"scripts": {
2924
"test": "npm run lint && npm run check && npm run testonly",
3025
"testonly": "mocha $npm_package_options_mocha",
26+
"t": "mocha --require resources/mocha-bootload",
3127
"lint": "eslint src",
3228
"check": "flow check",
33-
"build": "babel src --ignore __tests__ --out-dir dist/ && cp package.json dist/",
34-
"watch": "babel resources/watch.js | node",
29+
"build": "babel src --optional runtime --ignore __tests__ --out-dir dist/ && cp package.json dist/",
30+
"watch": "babel --optional runtime resources/watch.js | node",
3531
"cover": "babel-node node_modules/.bin/isparta cover --root src --report html node_modules/.bin/_mocha -- $npm_package_options_mocha",
3632
"cover:lcov": "babel-node node_modules/.bin/isparta cover --root src --report lcovonly node_modules/.bin/_mocha -- $npm_package_options_mocha",
3733
"preversion": ". ./resources/checkgit.sh && npm test",
@@ -43,17 +39,15 @@
4339
"devDependencies": {
4440
"babel": "5.8.21",
4541
"babel-core": "5.8.22",
46-
"babel-eslint": "4.0.10",
47-
"bluebird": "2.9.34",
48-
"chai": "3.2.0",
49-
"chai-subset": "1.0.1",
50-
"coveralls": "2.11.3",
51-
"eslint": "1.1.0",
42+
"babel-eslint": "4.1.7",
43+
"chai": "3.4.1",
44+
"chai-subset": "1.1.0",
45+
"coveralls": "2.11.4",
46+
"eslint": "1.10.1",
5247
"eslint-plugin-babel": "^2.1.1",
53-
"flow-bin": "0.14.0",
48+
"flow-bin": "0.20.1",
5449
"isparta": "3.0.3",
55-
"minimist": "1.1.3",
56-
"mocha": "2.2.5",
57-
"sane": "1.1.3"
50+
"mocha": "2.3.4",
51+
"sane": "1.3.0"
5852
}
5953
}

resources/prepublish.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ fi;
2121
#
2222
# var language = require('graphql/language');
2323
#
24-
babel src --ignore __tests__ --out-dir ./;
24+
babel --optional runtime src --ignore __tests__ --out-dir ./;

src/README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ var GraphQL = require('graphql'); // CommonJS
1212
Each sub directory within is a sub-module of graphql-js:
1313

1414
* `graphql/language`: Parse and operate on the GraphQL language.
15-
* `graphql/language/schema`: Parsing and operate on the GraphQL Schema language.
1615
* `graphql/type`: Define GraphQL types and schema.
1716
* `graphql/validation`: The Validation phase of fulfilling a GraphQL result.
1817
* `graphql/execution`: The Execution phase of fulfilling a GraphQL request.

src/__tests__/starWarsData.js

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -13,69 +13,69 @@
1313
* JSON objects in a more complex demo.
1414
*/
1515

16-
var luke = {
16+
const luke = {
1717
id: '1000',
1818
name: 'Luke Skywalker',
1919
friends: [ '1002', '1003', '2000', '2001' ],
2020
appearsIn: [ 4, 5, 6 ],
2121
homePlanet: 'Tatooine',
2222
};
2323

24-
var vader = {
24+
const vader = {
2525
id: '1001',
2626
name: 'Darth Vader',
2727
friends: [ '1004' ],
2828
appearsIn: [ 4, 5, 6 ],
2929
homePlanet: 'Tatooine',
3030
};
3131

32-
var han = {
32+
const han = {
3333
id: '1002',
3434
name: 'Han Solo',
3535
friends: [ '1000', '1003', '2001' ],
3636
appearsIn: [ 4, 5, 6 ],
3737
};
3838

39-
var leia = {
39+
const leia = {
4040
id: '1003',
4141
name: 'Leia Organa',
4242
friends: [ '1000', '1002', '2000', '2001' ],
4343
appearsIn: [ 4, 5, 6 ],
4444
homePlanet: 'Alderaan',
4545
};
4646

47-
var tarkin = {
47+
const tarkin = {
4848
id: '1004',
4949
name: 'Wilhuff Tarkin',
5050
friends: [ '1001' ],
5151
appearsIn: [ 4 ],
5252
};
5353

54-
var humanData = {
54+
const humanData = {
5555
1000: luke,
5656
1001: vader,
5757
1002: han,
5858
1003: leia,
5959
1004: tarkin,
6060
};
6161

62-
var threepio = {
62+
const threepio = {
6363
id: '2000',
6464
name: 'C-3PO',
6565
friends: [ '1000', '1002', '1003', '2001' ],
6666
appearsIn: [ 4, 5, 6 ],
6767
primaryFunction: 'Protocol',
6868
};
6969

70-
var artoo = {
70+
const artoo = {
7171
id: '2001',
7272
name: 'R2-D2',
7373
friends: [ '1000', '1002', '1003' ],
7474
appearsIn: [ 4, 5, 6 ],
7575
primaryFunction: 'Astromech',
7676
};
7777

78-
var droidData = {
78+
const droidData = {
7979
2000: threepio,
8080
2001: artoo,
8181
};

0 commit comments

Comments
 (0)