mirror of
https://github.com/makeplane/plane
synced 2024-06-14 14:31:34 +00:00
27 lines
609 B
TypeScript
27 lines
609 B
TypeScript
import React from "react";
|
|
import dynamic from "next/dynamic";
|
|
|
|
const RichTextEditor = dynamic(() => import("../components/lexical/editor"), {
|
|
ssr: false,
|
|
});
|
|
|
|
const LexicalViewer = dynamic(() => import("../components/lexical/viewer"), {
|
|
ssr: false,
|
|
});
|
|
|
|
const Home = () => {
|
|
const [value, setValue] = React.useState("");
|
|
const onChange: any = (value: any) => {
|
|
console.log(value);
|
|
setValue(value);
|
|
};
|
|
return (
|
|
<>
|
|
<RichTextEditor onChange={onChange} value={value} id="editor" />
|
|
<LexicalViewer id="institution_viewer" value={value} />
|
|
</>
|
|
);
|
|
};
|
|
|
|
export default Home;
|