Skip to content

Commit

Permalink
Switch json-stable-stringify to fast-json-stable-stringify. (#2065)
Browse files Browse the repository at this point in the history
* refactor: switch `json-stable-stringify` to `fast-json-stable-stringify`

* chore: drop `@types/json-stable-stringify`

* Update CHANGELOG.md for #2065.
  • Loading branch information
wtgtybhertgeghgtwtg authored and abernix committed Dec 19, 2018
1 parent bb2fc6d commit ccba8c8
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 23 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

### vNEXT

- Switch from `json-stable-stringify` to `fast-json-stable-stringify`. [PR #2065](https://github.com/apollographql/apollo-server/pull/2065)

### v2.3.1

- Provide types for `graphql-upload` in a location where they can be accessed by TypeScript consumers of `apollo-server` packages. [ccf935f9](https://github.com/apollographql/apollo-server/commit/ccf935f9) [Issue #2092](https://github.com/apollographql/apollo-server/issues/2092)
Expand Down
21 changes: 1 addition & 20 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@
"@types/graphql": "14.0.3",
"@types/hapi": "17.8.2",
"@types/jest": "23.3.10",
"@types/json-stable-stringify": "1.0.32",
"@types/koa-multer": "1.0.0",
"@types/koa-router": "7.0.35",
"@types/lodash": "4.14.119",
Expand Down
2 changes: 1 addition & 1 deletion packages/apollo-server-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@
"apollo-server-errors": "file:../apollo-server-errors",
"apollo-server-plugin-base": "file:../apollo-server-plugin-base",
"apollo-tracing": "file:../apollo-tracing",
"fast-json-stable-stringify": "^2.0.0",
"graphql-extensions": "file:../graphql-extensions",
"graphql-subscriptions": "^1.0.0",
"graphql-tag": "^2.9.2",
"graphql-tools": "^4.0.0",
"graphql-upload": "^8.0.2",
"json-stable-stringify": "^1.0.1",
"lodash": "^4.17.10",
"subscriptions-transport-ws": "^0.9.11",
"ws": "^6.0.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/apollo-server-core/src/utils/schemaHash.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { parse } from 'graphql/language';
import { execute, ExecutionResult } from 'graphql/execution';
import { getIntrospectionQuery, IntrospectionSchema } from 'graphql/utilities';
import stableStringify from 'json-stable-stringify';
import stableStringify from 'fast-json-stable-stringify';
import { GraphQLSchema } from 'graphql/type';
import { createHash } from 'crypto';

Expand Down
1 change: 1 addition & 0 deletions types/fast-json-stable-stringify/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export default function stringify(obj: any): string;

0 comments on commit ccba8c8

Please sign in to comment.