mirror of
https://github.com/aleleba/create-node-ts-graphql-server.git
synced 2025-01-08 21:16:49 -06:00
PR-448199:
Moving Server to src directory.
This commit is contained in:
parent
e9bc4f091f
commit
2b698e785a
3
.vscode/settings.json
vendored
Normal file
3
.vscode/settings.json
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"typescript.tsdk": "node_modules/typescript/lib"
|
||||||
|
}
|
@ -1,7 +1,7 @@
|
|||||||
'use strict';
|
'use strict';
|
||||||
import express from 'express'; //express
|
import express from 'express'; //express
|
||||||
import { graphqlHTTP } from 'express-graphql';
|
import { graphqlHTTP } from 'express-graphql';
|
||||||
import { config } from '../config';
|
import { config } from '../../config';
|
||||||
import schema from './schema';
|
import schema from './schema';
|
||||||
|
|
||||||
const server = express.Router();//Router de Express
|
const server = express.Router();//Router de Express
|
@ -8,7 +8,7 @@ import { useServer } from 'graphql-ws/lib/use/ws';
|
|||||||
import { execute, subscribe } from 'graphql';
|
import { execute, subscribe } from 'graphql';
|
||||||
import GraphQLserver from './GraphQL/server';// Server of GraphQL,
|
import GraphQLserver from './GraphQL/server';// Server of GraphQL,
|
||||||
import schema from './GraphQL/schema';
|
import schema from './GraphQL/schema';
|
||||||
import { config } from './config';
|
import { config } from '../config';
|
||||||
import apiRouter from './routes';
|
import apiRouter from './routes';
|
||||||
|
|
||||||
|
|
@ -13,7 +13,7 @@ const resolvePath = (...args) => path.resolve(ROOT_DIR, ...args);
|
|||||||
const BUILD_DIR = resolvePath('build');
|
const BUILD_DIR = resolvePath('build');
|
||||||
|
|
||||||
const config = {
|
const config = {
|
||||||
entry: './index.ts',
|
entry: './src/index.ts',
|
||||||
target: 'node',
|
target: 'node',
|
||||||
watch: true,
|
watch: true,
|
||||||
externals: [nodeExternals()],
|
externals: [nodeExternals()],
|
||||||
|
@ -13,7 +13,7 @@ const resolvePath = (...args) => path.resolve(ROOT_DIR, ...args);
|
|||||||
const BUILD_DIR = resolvePath('build');
|
const BUILD_DIR = resolvePath('build');
|
||||||
|
|
||||||
const config = {
|
const config = {
|
||||||
entry: './index.ts',
|
entry: './src/index.ts',
|
||||||
target: 'node',
|
target: 'node',
|
||||||
externals: [nodeExternals()],
|
externals: [nodeExternals()],
|
||||||
output: {
|
output: {
|
||||||
|
Loading…
Reference in New Issue
Block a user