-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: Add TypeScript typings to LmsApiService group methods (#1426)
docs: use AxiosResponse type refactor: LmsApiService group methods convert response to camelCase build: use @edx/typescript-config compilerOptions build: move typescript-config to devDependencies docs: separate pagination types and camelCase fields build: add trailing comma to tsconfig
- Loading branch information
1 parent
02cc629
commit d5fef09
Showing
8 changed files
with
78 additions
and
40 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
export type Paginated<ResultItem> = { | ||
next: string?, | ||
previous: string?, | ||
count: number, | ||
results: ResultItem[], | ||
}; | ||
|
||
export type PaginatedCurrentPage<ResultItem> = Paginated<ResultItem> & { | ||
currentPage: number, | ||
start: number, | ||
}; | ||
|
||
export type EnterpriseGroupType = 'budget' | 'flex'; | ||
|
||
export type EnterpriseGroup = { | ||
/* uuid of enterprise customer */ | ||
enterpriseCustomer: string, | ||
/* Group name */ | ||
name: string, | ||
/* Group uuid */ | ||
uuid: string, | ||
/* Number of accepted Group members */ | ||
acceptedMembersCount: number, | ||
/* Type of group */ | ||
groupType: EnterpriseGroupType, | ||
/* Date group was created */ | ||
created: string, | ||
}; | ||
|
||
export as namespace Types; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,9 @@ | ||
{ | ||
"extends": "@edx/typescript-config", | ||
"compilerOptions": { | ||
"allowJs": true, | ||
"allowSyntheticDefaultImports": true, | ||
"declaration": true, | ||
"esModuleInterop": true, | ||
"forceConsistentCasingInFileNames": true, | ||
"jsx": "react", | ||
"lib": ["dom", "es6", "dom.iterable"], | ||
"isolatedModules": true, | ||
"module": "ES6", | ||
"moduleResolution": "node", | ||
"noFallthroughCasesInSwitch": true, | ||
"noImplicitAny": false, | ||
"noImplicitThis": true, | ||
"noUnusedParameters": true, | ||
"skipLibCheck": true, | ||
"sourceMap": true, | ||
"strict": true, | ||
"strictFunctionTypes": false, | ||
"target": "ES6", | ||
"rootDir": ".", | ||
"outDir": "dist" | ||
"outDir": "dist", | ||
}, | ||
"include": ["src/**/*", "__mocks__/**/*"], | ||
"exclude": ["dist", "src/icons/*"] | ||
"exclude": ["dist", "src/icons/*"], | ||
} |