-
Notifications
You must be signed in to change notification settings - Fork 10
docs(examples): add roam demo #62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This pull request is being automatically deployed with Vercel (learn more). homebase-example-counter – ./examples/counter🔍 Inspect: https://vercel.com/homebaseio/homebase-example-counter/n2ilce9g4 homebase-example-todo – ./examples/todo🔍 Inspect: https://vercel.com/homebaseio/homebase-example-todo/1mzgj4qkg homebase-example-ts-firebase-todo – ./examples/typescript-firebase-todo🔍 Inspect: https://vercel.com/homebaseio/homebase-example-ts-firebase-todo/er9bcyhmw homebase-example-roam – ./examples/roam🔍 Inspect: https://vercel.com/homebaseio/homebase-example-roam/e3w1v24u5 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks really cool! Super excited to get this out there. I added some comments where I thought we could clarify more for developers what's going on. Also commented on some parts where I was impressed by the explanation and simplicity of code.
|
||
return ( | ||
<div className="my-4"> | ||
<Link to={`/page/${block.get('_children', 0, 'uid')}`} className="text-blue-500"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wondering if we should add a comment about this syntax and what it's doing since I don't think we document it anywhere?
return ( | ||
<div className="pl-6"> | ||
{children | ||
.filter((b) => b.get('id')) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is really cool
className="w-full outline-none bg-transparent" | ||
containerClassName="text-base flex" | ||
onChange={(e) => { | ||
// This instantly updates the UI |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comments here really helpful
transact([['retractEntity', id]]) | ||
} else if (e.key === 'Tab' && e.shiftKey) { | ||
e.preventDefault() | ||
const parent = block.get('_children', 0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ancestral naming here is really clear/self-explanatory :)
const updatedOrder = (order + nextSiblingOrder) / 2.0 | ||
try { | ||
transact([ | ||
// Unparent the current block |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
love these comments, really clear what's going on
) | ||
} | ||
|
||
const renderTextSection = (blockId) => (text, i) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This feels really clear despite being a bunch of regexes 🥇
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks great! 🚀
🎉 This PR is included in version 0.5.3 🎉 The release is available on: Your semantic-release bot 📦🚀 |
PR Description
PR Checklist
Testing
Docs
Typescript
Merging
For maintainers.
To merge, select "Squash and Merge". Then: