Use the yaml representation of the openapi used in Image Builder to load generate the RTKQ code.
20 lines
513 B
TypeScript
20 lines
513 B
TypeScript
import type { ConfigFile } from '@rtk-query/codegen-openapi';
|
|
|
|
const config: ConfigFile = {
|
|
schemaFile: '../schema/imageBuilder.yaml',
|
|
apiFile: '../../src/store/emptyImageBuilderApi.ts',
|
|
apiImport: 'emptyImageBuilderApi',
|
|
outputFile: '../../src/store/imageBuilderApi.ts',
|
|
exportName: 'imageBuilderApi',
|
|
hooks: true,
|
|
filterEndpoints: [
|
|
'getComposes',
|
|
'getComposeStatus',
|
|
'getComposeClones',
|
|
'getCloneStatus',
|
|
'getArchitectures',
|
|
'getPackages',
|
|
],
|
|
};
|
|
|
|
export default config;
|