feat(styling): add styled components#495
Merged
alejandronanez merged 2 commits intomasterfrom Oct 18, 2017
Merged
Conversation
alejandronanez
added a commit
to alejandronanez/awesome-styled-components
that referenced
this pull request
Oct 18, 2017
Waiting to merge gitpoint/git-point#495 this one before merging this change! Thanks for creating this library, it's awesome!
chinesedfan
reviewed
Oct 18, 2017
| }); | ||
| const Container = styled.View` | ||
| align-items: center; | ||
| background-color: ${() => colors.white} |
Member
There was a problem hiding this comment.
@alejandronanez I am not sure. Can it just be background-color: 'white'; ?
Member
There was a problem hiding this comment.
Doing it this way makes it so we can change the white color everywhere by just changing a single value. However, why can't we just do ${colors.white} @alejandronanez?
Member
Author
There was a problem hiding this comment.
Hey @chinesedfan
- We should avoid at all costs using plain strings for colors, that's not a good practice.
- We already have a
colorsfile that we should keep using.
Member
There was a problem hiding this comment.
@alejandronanez Yes, my point is the anonymous function, as @andrewda mentioned. (You merged so quickly. 😆 )
Member
Author
There was a problem hiding this comment.
@andrewda you're right! There you go https://github.com/gitpoint/git-point/pull/497/files
Member
Author
There was a problem hiding this comment.
Oh, I put a fix for that too @chinesedfan! :)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adding
styled-componentsinitial work! 🙌