kitten

kitten/use-editable

A small React hook to turn elements into fully renderable & editable content surfaces, like code editors, using contenteditable (and magic)

TypeScript
620
15
MIT License

`use-editable` is a lightweight React hook that transforms any element into a fully renderable and editable content surface, ideal for creating code editors or prose textareas without relying on raw HTML or heavy libraries. It leverages `contenteditable` with a `MutationObserver` to synchronize DOM changes with React's rendering, preserving cursor position and selection. This tool is perfect for developers building custom editors or interactive text components who want a minimal, flexible solution under 2kB.

Total donated
Undistributed
Share with your subscribers:

Recipients

How the donated funds are distributed

Support the dependencies

Support the repos that depend on this repository

Top contributors

kitten's profile
kitten
76 contributions
cpresler's profile
cpresler
2 contributions
jpdriver's profile
jpdriver
1 contributions
acharyakavita's profile
acharyakavita
1 contributions

Recent events

Kivach works on the Obyte network, and therefore you can track all donations.

No events yet