Skip to content
This repository has been archived by the owner on Jul 1, 2020. It is now read-only.

[Snyk] Upgrade styled-components from 5.0.0-beta.6-ej4 to 5.0.1 #48

Merged
merged 2 commits into from
Mar 10, 2020

Conversation

snyk-bot
Copy link
Contributor

Snyk has created this PR to upgrade styled-components from 5.0.0-beta.6-ej4 to 5.0.1.

ℹ️ Keep your dependencies up-to-date. This makes it easier to fix existing vulnerabilities and to more quickly identify and fix newly disclosed vulnerabilities when they affect your project.
  • The recommended version is 14 versions ahead of your current version.
  • The recommended version was released a month ago, on 2020-02-04.
Release notes
Package name: styled-components
  • 5.0.1 - 2020-02-04
    • Added useTheme hook to named exports for react native (#2982)

    • Performance enhancements

      • Refactored hashing function that is a bit faster in benchmarks (#2983)
      • Fixed a bitwise math issue that was causing SSR performance degradations due to how we allocate typed arrays under the hood (#2996)
    • Added some helpful new dev-time warnings for antipatterns

      • Recommending against usage of css @import inside createGlobalStyle and what to do instead (#2997)
      • Catching and warning against dynamic creation of styled-components inside other component render paths (#2998)
  • 5.0.1-revisedssr - 2020-02-13
  • 5.0.0 - 2020-01-13

    It's finally here!!! 🚀See the migrating to v5 FAQ page for easy upgrade instructions!

    Read the v5 release announcement!

    TL;DR:

    • 19% smaller bundle size
    • 18% faster client-side mounting
    • 17% faster updating of dynamic styles
    • 45% faster server-side rendering
    • RTL support

    ...and much more all, with no breaking changes!

    NOTE: At this time we recommend not using @import inside of createGlobalStyle. We're working on better behavior for this functionality but it just doesn't really work at the moment and it's better if you just embed these imports in your HTML index file, etc.

    Changes

    • StyleSheetManager enhancements

      • you can now supply stylis plugins like stylis-plugin-rtl; <StyleSheetManager stylisPlugins={[]}>...</StyleSheetManager>
      • disableVendorPrefixes removes autoprefixing if you don't need legacy browser support; <StyleSheetManager disableVendorPrefixes>...</StyleSheetManager>
      • disableCSSOMInjection forces using the slower injection mode if other integrations in your runtime environment can't parse CSSOM-injected styles; <StyleSheetManager disableCSSOMInjection>...</StyleSheetManager>
    • Removed the "subfunction" attrs syntax that was deprecated in v4

      styled.div.attrs({ role: p => p.onClick ? 'button' : '' })`
        color: red;
      `

      becomes

      styled.div.attrs(p => ({ role: p.onClick ? 'button' : '' }))`
        color: red;
      `
    • Update css-to-react-native to v3.0.0 (#2811); the one breaking change noted is that unitless line height is no longer allowed when setting font properties

    • disallow /ad/i in generated class names (#2837); this change primarily helps to avoid some overly aggressive ad blockers that will mangle generated classnames containing the substring "ad"

    • if you use styled-components from CDN, in v5 the "react-is" dependency was added (make sure you add this to your project)

  • 5.0.0-testgrouplimit.0 - 2020-01-30
  • 5.0.0-testdeopt2 - 2020-01-24
  • 5.0.0-testdeopt - 2020-01-22
  • 5.0.0-regexrehydrate - 2019-11-12
  • 5.0.0-rc.3 - 2019-12-30

    This should be the last RC before general v5 release in a week or two!

    NOTE: If you've been testing this stylisPlugins functionality with the stylis-rtl plugin, please switch from stylis-rtl to stylis-plugin-rtl.

    • make useTheme cleaner (#2879) props @sayjeyhi
    • unnecessary flattening and interleave of css without interpolations @vepor
    • switch back to mainline hoist-non-react-statics (#2934) …
    • use funding field instead of post install script (#2931) props @koba04
    • fix usage of nested stylesheetmanagers in SSR
    • expose version in API (#2888) props @jamesarmenta
    • refactor stylis management (#2936)
  • 5.0.0-rc.2 - 2019-11-12

    Note: we've switched from canary to v5 as the target branch for the new release. It's basically the same, but fixed up so it'll merge cleanly onto master.

    Changes from rc.1:

    • fix a few missed cases where attrs were not preferred over props (d2f4509)
    • remove the theme usage dev-time check (df36f93); this was done in master already, just forward-porting
    • aggregate classNames passed via attrs (#2859, 12a9f3c)
    • replace rehydration from CSSOM with progressive regex (#2872)
  • 5.0.0-rc.1 - 2019-10-31

    Changes from rc.0:

    • Inline mixin-deep so it is transpiled consistently for IE
  • 5.0.0-rc.0 - 2019-10-30

    We're almost there! After several months of work (thank you beta testers!) this is the first v5 release candidate build.

    Overall v5 changes:

    • Major performance and bundle size improvements over v4, see the announcement blog for more details!

    • StyleSheetManager enhancements

      • you can now supply stylis plugins like stylis-rtl; <StyleSheetManager stylisPlugins={[]}>...</StyleSheetManager>
      • disableVendorPrefixes removes autoprefixing if you don't need legacy browser support; <StyleSheetManager disableVendorPrefixes>...</StyleSheetManager>
      • disableCSSOMInjection forces using the slower injection mode if other integrations in your runtime environment can't parse CSSOM-injected styles; <StyleSheetManager disableCSSOMInjection>...</StyleSheetManager>
    • Removed the "subfunction" attrs syntax that was deprecated in v4

      styled.div.attrs({ role: p => p.onClick ? 'button' : '' })`
        color: red;
      `

      becomes

      styled.div.attrs(p => ({ role: p.onClick ? 'button' : '' }))`
        color: red;
      `

    Changes since the last beta:

    • disallow /ad/i in generated class names (#2837); this change primarily helps to avoid some overly aggressive ad blockers that will mangle generated classnames containing the substring "ad"

    • Update css-to-react-native to v3.0.0 (#2811); the one breaking change noted is that unitless line height is no longer allowed when setting font properties

    • replace merge-anything with mixin-deep (#2838); saving bytes, this is used when merging defaultProps for extended styled components

    • shard createGlobalStyle by runtime instance (#2824); cGS is implemented such that it's really meant to be used as a singleton, but it's not uncommon for people to have multiple instances of the same cGS component on the page at once. This change ensures that as instances and mounted and removed the existing global styles don't get removed as well

    • memoize theme (#2820); a minor performance tweak when ThemeProvider is given a reference-equal theme prop

    • make ThemeProvider error straightforward (#2787); more obvious messaging that the theme prop is required when using ThemeProvider

  • 5.0.0-fixhoist - 2019-12-22
  • 5.0.0-cgsmem - 2020-01-06
  • 5.0.0-beta.8-groupsizefix - 2019-08-22
  • 5.0.0-beta.6-ej4 - 2019-06-29
from styled-components GitHub release notes

Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open upgrade PRs.

For more information:

🧐 View latest project report

🛠 Adjust upgrade PR settings

🔕 Ignore this dependency or unsubscribe from future upgrade PRs

@willemliufdmg willemliufdmg merged commit 1b33fd2 into master Mar 10, 2020
@willemliufdmg willemliufdmg deleted the snyk-upgrade-cb4ea4e7f2c82f97d6f56bb81d797927 branch March 10, 2020 08:33
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants