gatsby-plugin-styled-components

    5.0.0 • Public • Published

    gatsby-plugin-styled-components

    A Gatsby plugin for styled-components with built-in server-side rendering support.

    Install

    npm install gatsby-plugin-styled-components styled-components babel-plugin-styled-components

    How to use

    Edit gatsby-config.js

    module.exports = {
      plugins: [
        {
          resolve: `gatsby-plugin-styled-components`,
          options: {
            // Add any options here
          },
        },
      ],
    }

    Options

    You can pass options to the plugin, see the Styled Components docs for a full list of options.

    For example, to disable the displayName option:

    options: {
      displayName: false
    }

    Note: The ssr option will be ignored. Gatsby will apply it automatically when needed.

    Disabling vendor prefixing

    If you don't require vendor prefixes for adding legacy CSS properties then this can be disabled by supplying the disableVendorPrefixes option:

    options: {
      disableVendorPrefixes: true
    }

    Install

    npm i gatsby-plugin-styled-components

    DownloadsWeekly Downloads

    96,247

    Version

    5.0.0

    License

    MIT

    Unpacked Size

    32.8 kB

    Total Files

    9

    Last publish

    Collaborators

    • dschau
    • kylemathews
    • pieh
    • sidharthachatterjee
    • wardpeet
    • vladar
    • tylerbarnes
    • fk
    • smthomas
    • lekoarts
    • rachelbahl
    • daniellewgatsby
    • veryspry
    • abhiaiyer
    • gutenye
    • freiksenet
    • monastic.panic
    • m-allanson
    • moocar