♻️ Remove modify id script in favor of openapi-ts config (#1434)
This commit is contained in:
@@ -10,6 +10,19 @@ export default defineConfig({
|
||||
name: "@hey-api/sdk",
|
||||
// NOTE: this doesn't allow tree-shaking
|
||||
asClass: true,
|
||||
operationId: true,
|
||||
methodNameBuilder: (operation) => {
|
||||
// @ts-ignore
|
||||
let name: string = operation.name
|
||||
// @ts-ignore
|
||||
let service: string = operation.service
|
||||
|
||||
if (service && name.toLowerCase().startsWith(service.toLowerCase())) {
|
||||
name = name.slice(service.length)
|
||||
}
|
||||
|
||||
return name.charAt(0).toLowerCase() + name.slice(1)
|
||||
},
|
||||
},
|
||||
],
|
||||
})
|
||||
|
Reference in New Issue
Block a user