Hacker News new | ask | show | jobs
by SebastianKra 776 days ago
Nice I'm kinda hoping that an Open-Source alternative to Raycast will eventually replace Command Line Interfaces outright. Like how Browsers offer primitives for responsive interfaces, these could become a platform for textual command/response interfaces...

I was positively surprised that you already have the React reconciler and interface components. I couldn't find the SWR hooks though.

Also, the interface isn't pretty atm.

And without knowing Raycast, I wouldn't understand why this is awesome. The Video could probably show more practical examples than Game of Life. Maybe have a short video of "here's how you implement a basic list-based command in 15 lines of code".

1 comments

> I couldn't find the SWR hooks though.

What do you have in mind?

> Also, the interface isn't pretty atm.

Agreed, creating pretty UIs is not my strongest suit if I am completely honest, and could use a help with that. But I have been polishing it up steadily, though sometimes it is an uphill battle with iced-rs.

> The Video could probably show more practical examples than Game of Life

Also agreed. Game of Life demo was supposed to show the interactivity of a view and was easy to implement but at some point I would like to add something more usable as a builtin plugin. For the code example I think it would be better to have that in documentation which is the next on my TODO list

All in all, good points

https://developers.raycast.com/utilities/react-hooks/useexec

useExec, useFetch and useSql these hooks follow the stale-while-revalidate principle, which handles fetching, refetching and caching. In combination with Raycasts loading indicators, this allows developers to work directly with the remote data without having to worry about loading/error states.