-
Notifications
You must be signed in to change notification settings - Fork 16
Expand file tree
/
Copy pathApp.module.ts
More file actions
60 lines (54 loc) · 1.51 KB
/
App.module.ts
File metadata and controls
60 lines (54 loc) · 1.51 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
import { Module } from '@nestjs/common';
import { GraphQLModule } from '@nestjs/graphql';
import path from 'path';
import { AssignmentModule } from './Assignment';
import { AssignmentFileModule } from './AssignmentFile';
import { AuthModule } from './Auth';
import { CharacterModule } from './Character';
import { CMSModule } from './CMS';
import { ConceptModule } from './Concept';
import { DatabaseModule } from './Database';
import { FriendModule } from './Friend';
import { LessonModule } from './Lesson';
import { ModuleModule } from './Module';
import { PathModule } from './Path';
import { PathUserModule } from './PathUser';
import { QuestionModule } from './Question';
import { StorySectionModule } from './StorySection';
import { UserModule } from './User';
import { UserConceptModule } from './UserConcepts';
import { UserModuleModule } from './UserModule';
/**
* Export these dependencies so they can be used in testing
*/
export const appImports = [
CMSModule,
AssignmentFileModule,
AssignmentModule,
AuthModule,
CharacterModule,
ConceptModule,
FriendModule,
LessonModule,
ModuleModule,
PathModule,
PathUserModule,
QuestionModule,
StorySectionModule,
UserConceptModule,
UserModule,
UserModuleModule,
DatabaseModule,
GraphQLModule.forRoot({
installSubscriptionHandlers: true,
autoSchemaFile: path.join(process.cwd(), 'src/schema.gql'),
context: ({ req }) => ({ req })
})
];
/**
* Main App module for NestJS
*/
@Module({
imports: appImports
})
export class AppModule {}