The number and size of JS dependencies required by this (awesome!) library are pretty huge relative to what it actually does. Installing from npm requires installing particular versions of react, react-dom, and cypress, to name a few. Makes it pretty hard to consider using in a non-tldraw application.
Looks like importing Vec from @tldraw is the primary culprit. I wonder if it's worth copying over Vec, though I know that's not as clean as a direct import. I'm obviously open to other approaches, and I'd be happy to submit a PR if it would be considered.
Hey, that's a good point, especially for the dev dependencies. Vec is a tiny library though (1.4kB gzipped), and I believe it's the only runtime dependency, so I don't think that should be an issue?
The number and size of JS dependencies required by this (awesome!) library are pretty huge relative to what it actually does. Installing from npm requires installing particular versions of react, react-dom, and cypress, to name a few. Makes it pretty hard to consider using in a non-tldraw application.
Looks like importing
Vec
from @tldraw is the primary culprit. I wonder if it's worth copying overVec
, though I know that's not as clean as a direct import. I'm obviously open to other approaches, and I'd be happy to submit a PR if it would be considered.