Provide support for using the css-in-js library Emotion including server side rendering. Uses the @emotion/babel-preset-css-prop.
This plugin is based on and adapted from the gatsby-plugin-emotion code.
This plugin supports Emotion v10+
npm install --save gatsby-plugin-emotion-css @emotion/core @emotion/css
Add the plugin to your gatsby-config.js
.
module.exports = {
plugins: [
{
resolve: `gatsby-plugin-emotion-css`,
options: {
// Accepts all options defined by `@emotion/babel-preset-css-prop` plugin.
},
},
],
};