- React for components
- GraphQL for client-side state management
- GraphQL for server queries and mutations
- Component definitions with co-located queries and mutations
- Two-level API:
- Low-level: Functions for creating components, mutations, queries
- High-level: Macro-based DSL for creating components, mutations, queries
- Prefer data over code (i.e. Hiccup-style UI definition)
- Encourage spec-driven development
- Server-side rendering
- React Native support out of the box
- React
- Sablono (for Hiccup-style UI definition)
- Apollo (for everything GraphQL)
groom.graphql: ClojureScript bindings for everything Apollo and GraphQLgroom.graphql.apollo.*: ClojureScript bindings for Apollogroom.graphql.graphql: ClojureScript bindings for GraphQL
groom.resolvers: Library for defining client-side query and mutation resolvers convenientlygroom.component: Low-level library for defining and rendering componentsgroom.dsl: High-level macro-based DSL for defining components, queries and mutations
groom.specs.v1: Specs for whatever makes sense (TODO: Work this out in more detail):groom.specs.v1/queriesfor Groom's Clojure-style query definitions:groom.specs.v1/mutationsfor Groom's Clojure-style mutation definitions
groom.specs.sablono.v1: Specs for Groom-enhanced Sablono UI definitionsgroom.specs.graphql.apollo.*: Specs for Groom's Apollo bindings
Groom requires boot and mach to be installed:
# boot
sudo bash -c "cd /usr/local/bin && curl -fsSLo boot https://github.com/boot-clj/boot-bin/releases/download/latest/boot.sh && chmod 755 boot"
# mach
sudo npm install -g @juxt/machThere is currently only one example, demonstrating a few simple components and basic client-side GraphQL state management. To play with it, run
boot starwars-exampleThen open http://localhost:8002/index.html in a browser.
The source code for this example is located in examples/starwars/src/starwars.cljs.
Groom is licensed under the MIT License.