enable CORS

This commit is contained in:
Taka Goto 2018-11-13 14:29:08 -06:00
parent 6a43cd4287
commit 1b6a9ac8a2
3 changed files with 3 additions and 0 deletions

View File

@ -28,6 +28,7 @@ describe('bootServer', () => {
options: {
pluginHook: jasmine.createSpy('pluginHook'),
watchPg: true,
enableCors: true,
simpleSubscriptions: true,
graphiql: true,
webSocketMiddlewares: [] },

View File

@ -12,6 +12,7 @@ export interface PostgraphileOptions {
pluginHook: PluginHookFn,
simpleSubscriptions: boolean;
watchPg: boolean;
enableCors: boolean;
graphiql: boolean;
// NOTE (jchristie@8thlight.com) Shape of the middlewares is not
// currently important to this application, but if a need arises,

View File

@ -28,6 +28,7 @@ export function buildServerConfig(
pluginHook: pluginHook,
simpleSubscriptions: true,
watchPg: true,
enableCors: true,
graphiql: true,
webSocketMiddlewares: [
expressSessionHandler,