Skip to content

[bug] react-select-fetch's url is improperly marked required. It is only required if you don't override get. #189

@soteri-scottmmjackson

Description

@soteri-scottmmjackson

url is marked required on react-select-fetch components. No it isn't. That isn't true.

Or, more specifically, it's only true iff get isn't overridden. Then it's... the url parameter that gets injected into your get method's first parameter. Whatever. My get method can easily hardcode that, and then I have to use one less prop. Or I would, if it wasn't marked as a required prop on the component.

Why don't we, as a compromise, mark url nullable and then say about here we do a runtime check to make sure we actually have a url or throw.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions