blakeembrey / change-case

Convert strings between camelCase, PascalCase, Capital Case, snake_case and more
MIT License
2.29k stars 97 forks source link

Fix change-case/keys types #337

Closed marcingajda closed 7 months ago

marcingajda commented 8 months ago

I fixed the TypeScript for change-case-keys, so it allows to pass options.

Instead of this

export declare const camelCase: (object: unknown, depth?: number) => unknown;
export declare const capitalCase: (object: unknown, depth?: number) => unknown;
...

it produces now this:

export declare const camelCase: (object: unknown, depth?: number, options?: changeCase.PascalCaseOptions | undefined) => unknown;
export declare const capitalCase: (object: unknown, depth?: number, options?: changeCase.Options | undefined) => unknown;
...
blakeembrey commented 7 months ago

Thanks for the catch!