DataScript: Immutable database and Datalog query engine in ClojureScript
1–10 of 30 posts
Re: DataScript: Immutable database and Datalog query engine in ClojureScript
#2Re: DataScript: Immutable database and Datalog query engine in ClojureScript
#3Would love to hear comments from anyone who has given DataScript a test drive - I'm guessing from the alpha state that no one is using it in production but hey, who knows... some people like to live dangerously.
Re: DataScript: Immutable database and Datalog query engine in ClojureScript
#4I love living dangerously, if danger means using full-stack Clojure and immutability -grin-
Re: DataScript: Immutable database and Datalog query engine in ClojureScript
#5These days everybody seems to throw around terms like immutable, isomorphic, pure etc. without actually knowing what they mean, or using them in contexts whey they don't make any sense.
Re: DataScript: Immutable database and Datalog query engine in ClojureScript
#6Immutable database? That doesn't make sense. If you can't mutate it, how do you write to it? How do you update records in it? If it's really immutable then you can't. Such a database is a compile-time constant. These days everybody seems to throw around terms like immutable, isomorphic, pure etc. without actually knowing what they mean, or using them in contexts whey they don't make any sense.
Re: DataScript: Immutable database and Datalog query engine in ClojureScript
#7Immutable database? That doesn't make sense. If you can't mutate it, how do you write to it? How do you update records in it? If it's really immutable then you can't. Such a database is a compile-time constant. These days everybody seems to throw around terms like immutable, isomorphic, pure etc. without actually knowing what they mean, or using them in contexts whey they don't make any sense.
You wrap that data-structure/database in a mutable reference type (an atom), like you do with any other data-structure in clojure if you need change.
Re: DataScript: Immutable database and Datalog query engine in ClojureScript
#8Immutable database? That doesn't make sense. If you can't mutate it, how do you write to it? How do you update records in it? If it's really immutable then you can't. Such a database is a compile-time constant. These days everybody seems to throw around terms like immutable, isomorphic, pure etc. without actually knowing what they mean, or using them in contexts whey they don't make any sense.
You don't write to the database, you perform an operation that takes a database and a write request and returns a new database. Same with updates. Essentially, the kind of things you think of as "mutating" operations have a signature of, in Haskell-ish notation:
db -> operation -> dbRe: DataScript: Immutable database and Datalog query engine in ClojureScript
#9There are some times when having a novel way to query could lead to simpler data.
Re: DataScript: Immutable database and Datalog query engine in ClojureScript
#10This is a project I've kept a closer eye on, as I'm thoroughly fascinated with Datomic, and the concept of using a similar system alongside functional approaches like React seems a good match. Would love to hear comments from anyone who has given DataScript a test drive - I'm guessing from the alpha state that no one is using it in production but hey, who knows... some people like to live dangerously.