api entities
This commit is contained in:
5
core/.prettierrc.json
Normal file
5
core/.prettierrc.json
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"semi": true,
|
||||
"trailingComma": "all",
|
||||
"singleQuote": true
|
||||
}
|
@ -1,5 +1,7 @@
|
||||
export type Entity = {
|
||||
export type EntityInfo = {
|
||||
uuid: string;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
};
|
||||
|
||||
export type EntityCtor = Partial<EntityInfo>;
|
||||
|
@ -1,2 +1,2 @@
|
||||
export * from "./user";
|
||||
export * from "./entity";
|
||||
export * from './user';
|
||||
export * from './entity';
|
||||
|
@ -1,10 +1,10 @@
|
||||
import { Entity } from "./entity";
|
||||
import { EntityInfo } from './entity';
|
||||
|
||||
export type UserInfo = {
|
||||
name: string;
|
||||
};
|
||||
|
||||
export type User = UserInfo & Entity;
|
||||
export type User = UserInfo & EntityInfo;
|
||||
|
||||
export type CreateUserBody = {
|
||||
name: string;
|
||||
@ -12,3 +12,5 @@ export type CreateUserBody = {
|
||||
};
|
||||
|
||||
export type LoginUserBody = CreateUserBody;
|
||||
|
||||
export type UserCtor = Partial<User>;
|
||||
|
@ -4,6 +4,7 @@
|
||||
"declarationMap": true,
|
||||
"composite": true,
|
||||
"sourceMap": false,
|
||||
"strictNullChecks": true,
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*"],
|
||||
|
Reference in New Issue
Block a user