Skip to content
This repository has been archived by the owner. It is now read-only.

Add topics chips #64

Merged
merged 5 commits into from Sep 15, 2017

Conversation

Projects
None yet
2 participants
@c-w
Copy link
Member

commented Sep 15, 2017

NB: there isn't an "x" to remove the maintopic filter because we always require the maintopic to be defined in the graphql queries.

@c-w c-w requested a review from erikschlegel Sep 15, 2017

@c-w c-w force-pushed the add-topics-chips branch 3 times, most recently from 7b2a34f to f29c6cf Sep 15, 2017

@c-w c-w force-pushed the add-topics-chips branch from f29c6cf to 24f5b1b Sep 15, 2017

let chips = [];
const { dataSource, externalsourceid, selectedplace } = this.props;
const { dataSource, externalsourceid, selectedplace, maintopic, termFilters } = this.props;
const chips = [];

This comment has been minimized.

Copy link
@erikschlegel

erikschlegel Sep 15, 2017

Collaborator

why is chips defined as a const if it's mutable?

This comment has been minimized.

Copy link
@c-w

c-w Sep 15, 2017

Author Member

It's a mutable object, not a mutable reference. Same reason why this works in Java:

final List<String> foo = new ArrayList<>();

// this works since foo is a mutable type
foo.add("something");

// this doesn't work since foo is an immutable reference
foo = new ArrayList<>();

@c-w c-w merged commit 77d6bc5 into master Sep 15, 2017

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

@c-w c-w deleted the add-topics-chips branch Sep 15, 2017

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.