Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Manage TypeScript declaration files using npm #162

Merged
merged 1 commit into from
Oct 3, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

### VNEXT
* Pass `ctx` instead of `ctx.request` to options function in Koa integration ([@HriBB](https://github.com/HriBB)) in [PR #154](https://github.com/apollostack/apollo-server/pull/154)
* Manage TypeScript declaration files using npm. ([@od1k](https:/github.com/od1k) in [#162](https://github.com/apollostack/apollo-server/pull/162))

### v0.3.2
* Added missing exports for hapi integration ([@nnance](https://github.com/nnance)) in [PR #152](https://github.com/apollostack/apollo-server/pull/152)
Expand Down
11 changes: 2 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,9 @@ Anyone is welcome to contribute to Apollo Server, just read [CONTRIBUTING.md](./

Apollo Server is super-easy to set up. Just npm-install apollo-server, write a GraphQL schema, and then use one of the following snippets to get started. For more info, read the [Apollo Server docs](http://dev.apollodata.com/tools/apollo-server/index.html).

### TypeScript
### Installation

If you want to build your GraphQL server using TypeScript, Apollo Server is the project for you. **NOTE**: All typings mentioned below must be included in your project in order for it to compile.

```sh
npm install apollo-server
typings i -SG dt~express dt~express-serve-static-core dt~serve-static dt~mime dt~hapi dt~boom dt~cookies dt~koa
```

For using the project in JavaScript, just run `npm install --save apollo-server` and you're good to go!
Just run `npm install --save apollo-server` and you're good to go!

### Express

Expand Down
22 changes: 21 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,31 @@
},
"homepage": "https://github.com/apollostack/apollo-proxy#readme",
"dependencies": {
"@types/body-parser": "0.0.33",
"@types/boom": "0.0.32",
"@types/chai": "^3.4.34",
"@types/connect": "^3.4.30",
"@types/cookies": "^0.5.30",
"@types/express": "^4.0.33",
"@types/express-serve-static-core": "^4.0.36",
"@types/fibers": "0.0.29",
"@types/hapi": "^13.0.35",
"@types/http-errors": "^1.3.29",
"@types/koa": "^2.0.33",
"@types/koa-bodyparser": "^3.0.19",
"@types/koa-router": "^7.0.21",
"@types/mime": "0.0.29",
"@types/multer": "0.0.32",
"@types/node": "^6.0.41",
"@types/serve-static": "^1.7.31",
"boom": "^4.0.0",
"http-errors": "^1.5.0",
"source-map-support": "^0.4.2"
"source-map-support": "^0.4.2",
"typed-graphql": "^1.0.2"
},
"devDependencies": {
"@types/mocha": "^2.2.32",
"@types/sinon": "^1.16.31",
"babel-cli": "^6.11.4",
"babel-core": "^6.11.4",
"babel-polyfill": "^6.9.1",
Expand Down
1 change: 1 addition & 0 deletions src/typings.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/// <reference types="typed-graphql" />
27 changes: 1 addition & 26 deletions typings.json
Original file line number Diff line number Diff line change
@@ -1,26 +1 @@
{
"dependencies": {
"chai": "registry:npm/chai#3.5.0+20160723033700",
"graphql": "github:nitintutlani/typed-graphql#ffe7e46e2249cc8f3824a5d15a44938f4354afe9",
"http-errors": "registry:npm/http-errors#1.4.0+20160723033700",
"sinon": "registry:npm/sinon#1.16.0+20160723033700"
},
"globalDependencies": {
"body-parser": "registry:dt/body-parser#0.0.0+20160619023215",
"boom": "registry:dt/boom#0.0.0+20160724101333",
"connect": "registry:dt/connect#3.4.0+20160317120654",
"cookies": "registry:dt/cookies#0.5.1+20160316171810",
"express": "registry:dt/express#4.0.0+20160708185218",
"express-serve-static-core": "registry:dt/express-serve-static-core#4.0.0+20160805091045",
"fibers": "registry:dt/fibers#0.0.0+20160317120654",
"hapi": "registry:dt/hapi#13.0.0+20160803202811",
"koa": "registry:dt/koa#2.0.0+20160724024233",
"koa-bodyparser": "registry:dt/koa-bodyparser#3.0.0+20160414124440",
"koa-router": "registry:dt/koa-router#7.0.0+20160314083221",
"mime": "registry:dt/mime#0.0.0+20160316155526",
"mocha": "registry:dt/mocha#2.2.5+20160720003353",
"multer": "registry:dt/multer#0.0.0+20160726135055",
"node": "registry:dt/node#6.0.0+20160801161248",
"serve-static": "registry:dt/serve-static#0.0.0+20160606155157"
}
}
{}