datascript
datascript copied to clipboard
Immutable database and Datalog query engine for Clojure, ClojureScript and JS
Here: https://github.com/tonsky/datascript/blob/6de343b1b3aecb95c21fbe46384face3f99b989b/src/datascript/impl/entity.cljc#L156 This breaks reactive programming semantics where, when `db` updates, `(d/entity db x)` updates but the result is `=` to the prior result and therefore continuous time reactive engines...
### Just an idea As someone pointed out (#130), a **faster** Datascript implementation is needed for applications with a lot of entities. Moreover, it would be great to have a...
Idents?
I'm so excited that you added lookup refs and upsert support! Trying them out right now. I noticed in the changelog you also added entid support - so does that...
With this query: ``` (q '[:find (count ?e) . :with ?i :where [?e :r ?e ?i]] [[1 :r 1 10] [2 :r 1 11]]) ``` I get `1` with Datomic...
The only use-case where this is needed and using a plain vector is not enough is resolving tempids: ``` {:db/valueType :db.type/tuple :db/tupleType :db.type/ref} ``` See also #364 and https://docs.datomic.com/on-prem/schema/schema.html#homogeneous-tuples
In datomic there is a way to combine data as ``` {:db/ident :x/y :db/valueType :db.type/tuple :db/tupleTypes [:db.type/ref :db.type/string], :db/cardinality :db.cardinality/one}` (or many). ``` I understand the `types` are more friendly...
In Datomic: ``` (q '[:where [(ground {}) ?m] [(assoc ?m :x 5) ?m2] :find ?m2 .]) ``` returns `{:x 5}`. But it fails in datascript with `clojure.lang.ExceptionInfo: Unknown function 'assoc...
This should make PRs show test results.
Attempting an upsert to an entity using its unique tuple attribute does not work as expected. Hope this example is clear: ```clojure (let [conn (d/create-conn {:player {:db/unique :db.unique/identity} :home {:db/valueType...
_This is a backwards compatible change that would vastly improve DX in my opinion_ I've always wondered: **why are entities not transactable?** I find myself converting entities to maps all...