Gatsby: Babel Plugin Styled Components must be a dev dependency?

Created on 4 Mar 2019  路  2Comments  路  Source: gatsbyjs/gatsby

When you visit https://www.gatsbyjs.org/packages/gatsby-plugin-styled-components/, I think babel-plugin-styled-components must be a dev dependency, not sure tho?

Right now it's

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

I think it must be changed to

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

Correct?

good first issue question or discussion

Most helpful comment

Some dependencies that other tools consider dev should be normal dependencies with Gatsby as e.g. on a CI server, often dev dependencies won't be installed which will break your gatsby build.

All 2 comments

Some dependencies that other tools consider dev should be normal dependencies with Gatsby as e.g. on a CI server, often dev dependencies won't be installed which will break your gatsby build.

Gotcha!

This is a naive example but suppose if many such dependencies are installed then won't it increase the build size?

Which dependencies are supposed to be normal vs dev? How would I differentiate?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

3CordGuy picture 3CordGuy  路  3Comments

ferMartz picture ferMartz  路  3Comments

rossPatton picture rossPatton  路  3Comments

ghost picture ghost  路  3Comments

mikestopcontinues picture mikestopcontinues  路  3Comments