Editor options
Override default editor options like max number of pages and animation speed.
import { Tldraw, TldrawOptions } from 'tldraw'
import 'tldraw/tldraw.css'
const options: Partial<TldrawOptions> = {
maxPages: 3,
animationMediumMs: 5000,
}
export default function CustomOptionsExample() {
return (
<div className="tldraw__editor">
<Tldraw persistenceKey="example" options={options} />
</div>
)
}
Use the options property to override tldraw's options. In this example, we limit the maximum number of pages to 3, and slow down camera animations like zoom in and zoom out.
Is this page helpful?
Prev
Tldraw componentNext
Shape options