Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
type: 'doc',
content: [
// { type: 'paragraph', content: [{ type: 'text', text: 'Woah' }] },
{
type: 'paragraph',
content: [
{
type: 'text',
marks: [{ type: 'enhancedLink', attrs: { href: 'http://Random.com' } }],
text: 'Random.com',
},
],
},
],
};
const string = renderSSREditor([new EnhancedLinkExtension({})], {
initialContent,
forceEnvironment: 'ssr',
});
expect(string).toInclude('http://Random.com');
expect(string).toMatchInlineSnapshot(`
<div class="css-1u8qly9">
<div class="Prosemirror remirror-editor" aria-label="" aria-multiline="true" role="textbox">
<p>
<a role="presentation" href="http://Random.com"></a></p></div></div>