A collection of ready to be used SCI configs.
This repository provides SCI configurations on the classpath. See the :dev
alias to check against which version of the libraries the configurations are
tested. You should bring in the dependency of targeted libraries yourself.
In general, a configuration can be enabled as in the following example for applied-science.js-interop:
(ns example
(:require [sci.configs.applied-science.js-interop :as j]
[sci.core :as sci]))
(def sci-ctx (doto (sci/init {}) ;; your initial config here
(sci/merge-opts j/config)))
(sci/eval-string* sci-ctx
"(require '[applied-science.js-interop :as j]) (j/assoc! #js {} :foo 1)")
;;=> #js {:foo 1}or if you like to include the config without calling sci/merge-opts (e.g. for
performance reasons), use the per-namespace values directly:
(ns example
(:require [sci.configs.applied-science.js-interop :as j]
[sci.core :as sci]))
(def sci-ctx (sci/init {:namespaces {'applied-science.js-interop j/js-interop-namespace}}))In general, only library/*-namespace and library/config vars are intented as the
public API. The rest is subject to breakage, even when vars are public. For
convenience, we list the public API for each library here.
Namespace: sci.configs.applied-science.js-interop
Public API:
configjs-interop-namespacenamespaces
Namespace: sci.configs.fulcro.fulcro
Public API:
confignamespaces
Namespace: sci.configs.cjohansen.dataspex
Public API:
configdataspex-core-namespacenamespaces
Namespace: sci.configs.cjohansen.replicant
Public API:
configreplicant-dom-namespacereplicant-string-namespacereplicant-alias-namespacenamespaces
Namespace: sci.configs.funcool.promesa
Public API:
configpromesa-namespacepromesa-protocols-namespacenamespaces
Namespace: sci.configs.metosin.reitit
Public API:
configfrontend-namespacefrontend-easy-namespacenamespaces
Namespace: sci.configs.reagent.reagent
Public API:
configreagent-namespacereagent-ratom-namespacereagent-debug-namespacenamespaces
Configurations for reagent.dom.server and reagent.dom.client are available seperately via:
Namespace: sci.configs.reagent.reagent-dom-server
Public API:
configreagent-dom-server-namespace
Namespace: sci.configs.reagent.reagent-dom-client
Public API:
configreagent-dom-server-namespace
Namespace: sci.configs.re-frame.re-frame
Public API:
configre-frame-namespacere-frame-db-namespacenamespaces
The configuration for re-frame.alpha is available seperately via:
Namespace: sci.configs.re-frame.re-frame-alpha
Public API:
configre-frame-alpha-namespace
Namespace: sci.configs.mfikes.cljs-bean
Public API:
confignamespacescljs-bean-namespace
Namespace sci.configs.cljs.test
Public API:
confignamespacescljs-test-namespace
Public API:
confignamespacescljs-pprint-namespace
Public API:
confignamespacescore-namespacedb-namespace
Namespace: clojure.core
New functions added to clojure.core in version 1.11
namespaces
Namespaces: cljs.spec.alpha, cljs.spec.gen.alpha, cljs.spec.test.alpha
Public API:
confignamespaces
npm install and bb test
You can play with your SCI code and configs in a cljs REPL. In Calva, run Jack-in to a shadow-cljs repl and choose the :dev build. Elsewhere, run bb dev and then connect to its nrepl at port 9000. Access the web page that Shadow serves at http://localhost:8081/ and then eval your code using development.cljs.
The configurations are licensed under the same licenses as the libraries they target. You are free to take the configs from this repository and adapt them as necessary for your projects. See LICENSE for additional info.