Get unlimited public & private packages + package-based permissions with npm Pro.Get started »

apollo-module-date

1.0.8 • Public • Published

Introduction

Allows to use Date in your graphql schema. Requires to use apollo-mantra tools to import into your schema.

This module requires to use apollo-modules to build your modular graphql schema.

// file modules.js
import date from 'apollo-module-date';
import { addModules } from 'apollo-modules';
...
 
export default function() {
    addModules([
    date,
    ... // your other schemas
  ]);
}
 
// file apollo.js
import initSchema from './modules';
 
const modules = initSchema();
const schema = makeExecutableSchema({ typeDefs: modules.schema, resolvers: modules.resolvers });
 
... // your usual apollo code

Install

npm i apollo-module-date

DownloadsWeekly Downloads

4

Version

1.0.8

License

MIT

Unpacked Size

2.82 kB

Total Files

5

Last publish

Collaborators

  • avatar