graphql-paper
Version:
A flexible in-memory store based on a GraphQL Schema
12 lines (10 loc) • 316 B
JavaScript
;
var constants = require('../constants.js');
function getDocumentKey(keyOrDocument) {
if (typeof keyOrDocument === 'string') {
return keyOrDocument;
}
return keyOrDocument[constants.DOCUMENT_KEY_SYMBOL];
}
exports.getDocumentKey = getDocumentKey;
//# sourceMappingURL=get-document-key.js.map