Skip to content

Releases: styled-components/styled-components

v6.0.0-alpha.5

24 Mar 14:52
Compare
Choose a tag to compare
v6.0.0-alpha.5 Pre-release
Pre-release
  • Fix types associated with styled-components/macros
  • Add optional peer dependency for babel-plugin-styled-components (required for macros)

Updated sandbox for alpha: https://codesandbox.io/s/styled-components-v6-alpha-sandbox-05bod1?file=/src/App.tsx

Full Changelog: v6.0.0-alpha.4...v6.0.0-alpha.5

v6.0.0-alpha.4

24 Mar 14:42
Compare
Choose a tag to compare
v6.0.0-alpha.4 Pre-release
Pre-release
  • Added type for CSSProp (this is in definitely typed but wasn't exposed by us)
  • Exposed more base types

Recommended styled-components.d.ts setup for your project:

// create styled-components.d.ts in your project source
// if it isn't being picked up, check tsconfig compilerOptions.types
import type { CSSProp } from 'styled-components';
import Theme from './theme';

type ThemeType = typeof Theme;

declare module 'styled-components' {
  export interface DefaultTheme extends ThemeType {}
}

declare module 'react' {
  interface DOMAttributes<T> {
    css?: CSSProp;
  }
}

Full Changelog: v6.0.0-alpha.2...v6.0.0-alpha.4

v6.0.0-alpha.2

24 Mar 13:37
Compare
Choose a tag to compare
v6.0.0-alpha.2 Pre-release
Pre-release

Added "types" package.json fields for TS type acquistion.

Full Changelog: v6.0.0-alpha.1...v6.0.0-alpha.2

v5.3.5

24 Mar 14:38
Compare
Choose a tag to compare

Add statement of solidarity against the war on Ukraine 馃嚭馃嚘

v6.0.0-alpha.1

24 Feb 13:43
Compare
Choose a tag to compare
v6.0.0-alpha.1 Pre-release
Pre-release

Fixed the TS declarations not getting emitted correctly by rollup.

Full Changelog: .v6.0.0-alpha.0...v6.0.0-alpha.1

v6.0.0-alpha.0

22 Feb 21:56
Compare
Choose a tag to compare
v6.0.0-alpha.0 Pre-release
Pre-release

After an epic amount of refactoring, I'm pleased to announce the first alpha of styled-components v6!

Highlights:

  1. styled-components is now written in TypeScript and ships its own types
  2. stylis v4
  3. tons of bug fixes
  4. node 14+ now required

Full Changelog: v5.2.0...v6.0.0-alpha.0

v5.3.3

19 Oct 13:37
Compare
Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v5.3.1...v5.3.3

v5.3.1

24 Aug 15:06
5aa0af3
Compare
Choose a tag to compare
  • Fix forced server-side mode not triggering global styles (See #3566)

  • Fix SSR collisions caused by insufficient hash inputs and reordering of groups on the client, which is a regression in v5.2.0 (See #3563)

  • Fix dynamic creation React warning for React v18, backported to v5 by @lynndylanhurley (See #3564)

  • Add missing typeof window check when checking for duplicate instances of styled-components (See #3553)

  • Prevent ServerStyleSheet from emitting empty style tags, which would cause issues in IE11 (See #3555)

  • Support css tagged templates inside style objects, by @roginfarrer and @dvingo (See #3469)

v5.3.0

05 May 02:17
Compare
Choose a tag to compare
  • Pass elementToBeCreated as a third parameter to shouldForwardProp so that the user-specified function can decide whether to pass through props based on whether the created element will be a tag or another component. (see #3436)

  • Fix React Native components accepts function as style prop. (see #3389)

v5.2.3

31 Mar 14:16
Compare
Choose a tag to compare

fix an issue with an unguarded window accessor in a SSR path (see #3446)