diff --git a/packages/schema/src/index.ts b/packages/schema/src/index.ts index 5182ce39..71f74aa3 100644 --- a/packages/schema/src/index.ts +++ b/packages/schema/src/index.ts @@ -1,30 +1,4 @@ -import { course, courseRelations } from "./schema/course"; -import { courseHistory } from "./schema/courseHistory"; -import { coursePack, coursePackRelations } from "./schema/coursePack"; -import { membership } from "./schema/membership"; -import { statement, statementRelations } from "./schema/statement"; -import { userCourseProgress } from "./schema/userCourseProgress"; -import { userLearnRecord } from "./schema/userLearnRecord"; +export * from "./schema"; +export * as schemas from "./schema"; -export * from "./schema/course"; -export * from "./schema/courseHistory"; -export * from "./schema/statement"; -export * from "./schema/userLearnRecord"; -export * from "./schema/userCourseProgress"; -export * from "./schema/membership"; -export * from "./schema/coursePack"; - -export const schemas = { - course, - statement, - statementRelations, - membership, - userCourseProgress, - courseHistory, - userLearnRecord, - coursePack, - courseRelations, - coursePackRelations, -}; - -export type SchemaType = typeof schemas; +export type SchemaType = typeof import("./schema"); diff --git a/packages/schema/src/schema/index.ts b/packages/schema/src/schema/index.ts new file mode 100644 index 00000000..9722e2a0 --- /dev/null +++ b/packages/schema/src/schema/index.ts @@ -0,0 +1,7 @@ +export * from "./course"; +export * from "./courseHistory"; +export * from "./statement"; +export * from "./userLearnRecord"; +export * from "./userCourseProgress"; +export * from "./membership"; +export * from "./coursePack";