This is an extension for CodeMirror 6 to add a clickable link icon next to a valid URL.
First you need to add the extension :
npm i cm6-texttolink
And then import the function :
import { TextToLink, hyperLinkStyle } from 'cm6-texttolink'
And then you can add the functions to extension array :
let extension = [ basicSetup, TextToLink(EditorView), hyperLinkStyle ];
SVG Icon and CSS style are from @uiwjs/react-codemirror/hyper-link
MIT