Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mark ky.create() options as optional in public types #628

Merged
merged 1 commit into from
Sep 2, 2024

Conversation

dirkluijk
Copy link
Contributor

Just a small tweak on the ky.create(). I know it's also possible to use the global ky instance, but just in case one wants to use this factory method instead.

@sholladay
Copy link
Collaborator

This actually makes the types more consistent because the create() options are already marked optional here:

ky.create = (newDefaults?: Partial<Options>) => createInstance(validateAndMerge(newDefaults));

Thanks!

@sholladay sholladay changed the title fix: make options optional in ky.create() Mark ky.create() options as optional in public types Sep 2, 2024
@sholladay sholladay merged commit 8d2ca91 into sindresorhus:main Sep 2, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants