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

Filtering #59

Merged
merged 23 commits into from
Apr 21, 2017
Merged

Filtering #59

merged 23 commits into from
Apr 21, 2017

Conversation

PrashanthKumarM
Copy link
Contributor

3 filters implemented. The ones based on list options (documentRouteStatus, documentType and actionRequested)

onSort: criteria => dispatch(sortActionList(criteria)),
});

/* eslint-enable no-unused-vars */
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove this eslint exception

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed!!

Copy link
Contributor

@burnumd burnumd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR looks good. If you would, please, just extract the repeated<View style={style.header}><Text style={style.headerText}>{/* text */}</Text></View> segments into a Header component so they can be reused consistently.


const ContentHeader = ({ title }) => (
<View>
<Text style={style.headerText}>{title}</Text>
Copy link
Contributor

@burnumd burnumd Apr 20, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd recommend not using a title prop and just use the children prop. It looks like it's allowed for Text components to have node children, so if you just use children you can pass off prop validation to the react-native component and allow yourself more flexibility.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried to use children and lint threw an error saying I need to have a prop validation for it

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, the type of children should be documented as React.PropTypes.node: jsx-eslint/eslint-plugin-react#7

# Conflicts:
#	actionlist/app/containers/PreferencesContainer.js
@PrashanthKumarM PrashanthKumarM merged commit 516f4ee into develop Apr 21, 2017
@PrashanthKumarM PrashanthKumarM deleted the filtering branch April 21, 2017 19:12
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.

None yet

3 participants