diff --git a/www/src/pages/examples/Example674.tsx b/www/src/pages/examples/Example674.tsx new file mode 100644 index 000000000..0642e0199 --- /dev/null +++ b/www/src/pages/examples/Example674.tsx @@ -0,0 +1,35 @@ +import CodeMirror from '@uiw/react-codemirror'; +import { EditorView } from '@uiw/react-codemirror'; +import { Fragment, useCallback, useState } from 'react'; + +const code = `## Title + +[weisit ulr](https://uiwjs.github.io/react-codemirror/) +four +**Bold text** +`; + +/** + * https://github.com/uiwjs/react-codemirror/issues/674 + */ +export function Component() { + const [value, setValue] = useState(code); + + const onChange = useCallback((val: string) => { + setValue(val); + }, []); + + return ( + + + + ); +} diff --git a/www/src/router.tsx b/www/src/router.tsx index 0b05d8799..f9a2ad589 100644 --- a/www/src/router.tsx +++ b/www/src/router.tsx @@ -658,6 +658,11 @@ export const routes: MenuRouteObject[] = [ label: 'How to remove all syntax highlighting?', lazy: () => import('./pages/examples/Example431'), }, + { + path: '674', + label: 'Browser spell checking', + lazy: () => import('./pages/examples/Example674'), + }, { path: '455', label: 'CodeMirrorMerge use theme',