I think the issue here for everyone is not that the mock data is being generated incorrectly, the issue, in my opinion, is that the recommended code snippet for Key Text recommends the PrismicText component and this causes an error.
Key text should just be {slice.field}. But in the “Widget” Slice Machine tells you to use <PrismicText field={slice.field} /> , but <PrismicText /> doesn't want just a string.
So the correct way to use a ket text is...
const HeroHeader = ({ slice }) => {
return <p>{slice.primary.text}</p>
}
This has been updated in the latest versions of Slice Machine, add should appear in the code snippets like so:
<span >{ slice.primary.text }</span>