crank
crank copied to clipboard
Question around beta phase / roadmap
Hey 👋
Great job 🎉 This is a refreshing view on writing UI components.
I'm curious on what work is left for the beta phase and do you have an idea of the roadmap for the library? I'm interested in contributing and I'm sure others are too.
I wrote a list in the reddit post on r/javascript which I’ll copy over here:
- More docs: I still haven’t documented a couple features like the Crank equivalent for React contexts and style props and such.
- More tests: I’m pretty sure my DOM renderer is gonna be buggy on a couple edge cases like html tables and SVG and I just haven’t had the time yet to figure out what to do here. Cross-browser/performance testing would also be nice. Maybe I can leverage these new stars for a browserstack/saucelabs plan.
- More methods on the context: This might be most approachable to work on. I was thinking we should add more methods to the this object, like I would love a
fetch
method which automatically aborted when the component was unmounted, or asetTimeout
which automatically cancelled. Maybe we could create a strongly typed plugin system so users could write their own logic. It would be yet another tool in the toolbelt to answer for React hooks. - More complete EventTarget class: Currently, we’re relying on event-target-shim, which is nice but doesn’t provide event parents or capturing. I have a hacky solution but I definitely want to get rid of the dependency and just have a solution which handles all the use-cases required by Crank.
- A meta-framework: If you look at the website, it’s dogfooded Crank, but it only uses the server-side renderer. I’d like to maybe expand on the code, or see if some other meta-framework which isn’t hard-coded to React can be used.
- Web components: I want to create imperative interfaces with Crank so it can be embedded in applications running other frameworks, and I think the WebComponent inheritance-based HTMLElement classes could definitely help us here.
-
h
alias forcreateElement
: People are really into this for some reason, dunno why. - Styled components: I really like Linaria for React. If you want to make a styled component thingy for Crank I’d be super interested.
- Animations: I love spring animations and I’m wondering what that looks like for Crank.
- Async unmounting of components: Right now, async generator components unmount asynchronously, but we throw that promise away. I want to do something with this promise for exit animations. I need to think more about the API but this would be a gamechanger.
7.
h
alias forcreateElement
: People are really into this for some reason, dunno why.
that's something I saw in vue, never understood why h
, but I also did it :D
Threw together a thin wrapper around Emotion for styling components if anyone wants to give it shot! https://github.com/jpbow/cronk
@jpbow Loving the naming and branding
@jpbow oh my god you already have a mascot and I don’t even have a logo for Crank lol
@brainkim I'd like to put forward a vote for Kronk to be the mascot of the whole Crank ecosystem
- Cronk -> Kronk
- Crank -> Clank?
I think it’d be great to have crank-testing-library. https://testing-library.com/docs/intro. Frameworks like React, Vue, and Riot have their own packages and it’d be a nice transition for devs who are used to testing library in their framework of choice.
I’m going to get started on this and will post an issue seeking feedback/help.