kit
react-query
Our great sponsors
kit | react-query | |
---|---|---|
34 | 190 | |
445 | 27,869 | |
2.7% | - | |
8.1 | 9.1 | |
about 2 months ago | almost 2 years ago | |
Clojure | TypeScript, JS | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
kit
-
Ask HN: What is your go-to stack for the web?
Clojure using for the server side https://github.com/kit-clj/kit
htmx for frontend, using the built-in kit htmx module.
- Kit – Clojure Web Development
-
Why Is Jepsen Written in Clojure?
I am not sure what a web framework is, to be honest. The choices for many parts of a web application are really domain-specific and I'm not sure a single "framework" would work for everyone.
As far as web-related components go, my app uses Rum (as an interface to React), ring, http-kit, pushy (for history manipulation), sente (for websockets), buddy (for authentication tools).
If you are looking for a batteries-included "I want to have some sort of webapp right away" thing, I think https://kit-clj.github.io would fit the bill, but the general feeling in the Clojure community is that unlike Python with Django or Ruby with Rails, the choice of app components is not predetermined by the language.
- A History of Clojure (2020) [pdf]
-
Most commonly used libraries/frameworks in Clojure
Luminus has, in theory, been superseded by Kit: https://kit-clj.github.io/ but even so it is still "an opinionated bundle of libraries" rather than a framework.
-
Is there an open source project focused on ClojureScript, React, Reagent?
I learned by using https://luminusweb.com/docs/clojurescript.html to get me started. It gives you a plethora of sane starting points, and you can just work on switching it to your own business logic. Troubleshooting and adding functionality will usually lead you to understand how things work. The authors of luminus have moved on to build kit: https://kit-clj.github.io/ which is probably another good starting point.
- Help finding a webdev framework that works out of the box
-
Clojure Turns 15 panel discussion video
The cljs stack I hear about a lot (and use) is ShadowCLJS with reagent (https://reagent-project.github.io/) and re-frame (https://day8.github.io/re-frame/). ShadowCLJS is more of a build tool, but is really well documented and easy to use. Reagent is basically react but a simpler API, and re-frame is a layer on top of that provides data subscriptions and event-handlers to manage app state. It's overkill for some apps but I find it's actually super easy to work with and not as much complexity as I thought.
For backend there is luminus (https://luminusweb.com/) or Kit (https://kit-clj.github.io/). They are basically project templates that wire together a ton of popular solutions for various things - database access, migrations, security, html templating, etc. Also includes frontend frameworks like re-frame if you want.
-
your thoughts on the kit framework?
The component itself is just a thin wrapper for conman, you can see it here.
-
Ask HN: Share Your Personal Site
Here’s me: https://luciano.laratel.li/
I was happy I could get the domain! Pretty simple hand-rolled server-rendered site using the kit-clj[0] and neat-css[1]. Main backbone of the site is here[2]. I used to use a CLJS SPA but it was overkill and not as nice to use (load times particularly.)
[0]: https://kit-clj.github.io/
react-query
-
20 Essential Parts Of Any Large Scale React App
react-query
-
Some Very Cool (Underrated maybe) React Libraries
React Query: This library makes it easy to manage data in your React applications, from fetching to caching and updating data. It offers a simple, powerful, and flexible API for handling data and keeping your UI in sync with your data. https://github.com/tannerlinsley/react-query
-
Do I need a fetching library in React?
useQuery (react-query) (+) all from above (+) even more features (-) more complex, even the examples are complex, has more aggressive defaults (re-fetching every 2s)
-
Is there any redux-saga equivalent for zustand?
see here Overview
-
React Query Codegen from OpenAPI
Rapini is a new tool that can generate custom React Query hooks using OpenAPI (Swagger) files.
-
React hooks for 28 RxJS operators
React Query is the gold standard for using async data declaratively with hooks. I ended up needing to modify even my simple useTimer hook to work more like useQuery to take multiple keys in order to work as an inner observable for other operators.
-
Goodbye, useEffect - Reactathon 2022
For most situations, I would recommend using a library like React Query. It handles a lot of common data-fetching boiler plate and already accounts for this useEffect() issue. Also, it supports Suspense if you want to use that.
-
Managing application cache with react-query, and code generation.
At this point, I want to move on to the react-query cache management library. Give a brief overview and see how you can improve your developer experience with cache using this library.
-
When to use a hook, and when to use a service?
There isn't the "service" concept in React. If you need to send off data you can just do so with fetch. If you need to load data and cache it so it can be used across components and unmounts, then something like react-query is what I'd recommend. But it's basically a combination of React Context, useEffect, and useState to manage the cache and lifecycle of a request.
-
What would you consider to be a must for a modern 2022 dev stack?
react-query is pretty neat too. I default to that for most projects unless it's something unusual
What are some alternatives?
biff - A Clojure web framework for solo developers.
SWR - React Hooks for Data Fetching
duct - Server-side application framework for Clojure
axios - Promise based HTTP client for the browser and node.js
re-frame-template - A Leiningen template for creating a re-frame application (client only) with a shadow-cljs build.
redux-saga - An alternative side effect model for Redux apps
clojure-inertia-pingcrm-demo - PingCRM on Clojure - A Clojure/Script fullstack demo application to illustrate how Inertia.js works.
rtk-query - Data fetching and caching addon for Redux Toolkit
usermanager-reitit-integrant-example - A little demo web app in Clojure, using Integrant, Ring, Reitit, Selmer (and a database)
zustand - 🐻 Bear necessities for state management in React
initializr - A quickstart generator for Spring projects
Recoil - Recoil is an experimental state management library for React apps. It provides several capabilities that are difficult to achieve with React alone, while being compatible with the newest features of React.