apollo-server-plugin-error
v2.0.1
Published
apollo-server plugin that handle errors
Downloads
944
Readme
Usage
import { ApolloServerPluginError } from 'apollo-server-plugin-error';
...
const server = new ApolloServer({
...,
plugins: [
new ApolloServerPluginError((error) => {
// here you handle the error as you want
console.error(error);
})
],
});
Install
# via npm
npm install apollo-server-plugin-error
# or via yarn
yarn add apollo-server-plugin-error