Migrate to Netlify Today

Netlify announces the next evolution of Gatsby Cloud. Learn more

ContactSign Up
Community Plugin
View plugin on GitHub

Description

Basic transformer plugin enabling users to retrieve inline SVG processed by SVGO via Gatsby’s GraphQL API.

How to install

npm install gatsby-transformer-svgo-inline

or

yarn add gatsby-transformer-svgo-inline

Available options

  • svgoConfig is passed through to SVGO.

When do I use this plugin?

Author’s use case

I wanted to specify SVG’s within data structures (e.g. Markdown front-matter) and retrieve the optimized inline markup in the same query as for the rest of the front-matter.

To-do’s

  • “Examples of usage” in this README.
  • Consider adding logic to behave differently as a function of gatsby-source-filesystem source instance.
© 2023 Gatsby, Inc.