joshwcomeau/guppy

Upgrade to `styled-components` v4

オープン

#213 opened on 2018/09/05

 (6 件のコメント) (5 件のリアクション) (1 人の担当者)JavaScript (151 件のフォーク)github user discovery
code healthgood first issue

Repository metrics

Stars
 (3,240 個のスター)
PR merge metrics
 (30d に merged PR はありません)

説明

styled-components v4 was just announced, and it looks really good:

  • 25% faster on mount
  • really good new APIs like the new global styles, and as
  • ref support
  • faster styled()
  • a bunch more

It's still in beta, but I think we should try upgrading. It seems like it'd be a huge improvement.

Some things that will need to be updated:

  • We use injectGlobal in a few places, needs to switch to the new global API
  • use ref instead of innerRef in a few places
  • use styled() instead of .extend
  • For the Heading component, we can use the new as prop, instead of withComponent

This would be a great first issue for new contributors :) would give you a tour of the React codebase, without being too hairy.

コントリビューターガイド