styled-default
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

styled-default

A carefully crafted browser defaults for styled-components.

Installation

npm:

npm install --save-dev styled-default

Yarn:

yarn add --dev styled-default

Usage with styled-components

// global-style.js
import { createGlobalStyle } from 'styled-components';
import reset from 'styled-default';
const GlobalStyle = createGlobalStyle`
  ${reset}
  /* other styles */
`
export default GlobalStyle;
// app.js
import GlobalStyle from './global-style';
const App = () => (
  <>
    <GlobalStyle />
    <div>Hi!</div>
  </>
}
export default App;

You can also use named imports:

// ES Modules
import { reset } from 'styled-default';
// CommonJS
const { reset } = require('styled-default');

License

MIT

Package Sidebar

Install

npm i styled-default

Weekly Downloads

1

Version

1.0.0

License

MIT

Unpacked Size

17.5 kB

Total Files

5

Last publish

Collaborators

  • ahmadhuss