Currently in my project I have a folder with all my svg files, the query to get them from graphql is as follows:
query AssetsPhotos {
allFile(filter: {extension: {regex: "/(svg)/"}, relativeDirectory: {eq: "svg"}}) {
edges {
node {
id
name
}
}
}
}
but unlike image files (.png, jpg, etc) I don't have the GatsbyImageData option, how could I render them if I want something like this:
{SgvsData.map(({ image,id,title}) => (
<GatsbyImage image={getImage(image.gatsbyImageData)} alt={title} key={id} />
))}
I tried options like publicUrl, children and childImageSharp, but the image doesn't render. Thank you very much in advance