I am importing data from an external API into my sanity schema and the API contains the slug in the form of a string. I have tried removing the double quotes of the string and making it single quoted but that is still not accepted by sanity as slug type.
So how do I convert it to the slug type?
code I'm currently using:
const slicedSlug = externalReport.slug.replace(/["]+/g, '');