Skip to content

Required Props need to be relaxed #132

Open
@landonreed

Description

@landonreed

The props API is a little needy. We should be defining noops for functions that are not necessarily required. Also, below this, the location defaultProp is set to undefined. Not really sure that's necessary.

Endpoint.propTypes = {
clearLocation: PropTypes.func.isRequired,
forgetPlace: PropTypes.func.isRequired,
location: locationType,
locations: PropTypes.arrayOf(locationType).isRequired,
MapMarkerIcon: PropTypes.elementType.isRequired,
rememberPlace: PropTypes.func.isRequired,
setLocation: PropTypes.func.isRequired,
showUserSettings: PropTypes.bool.isRequired,
type: PropTypes.string.isRequired
};
Endpoint.defaultProps = {
location: undefined
};

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions