Why are Datomic attributes are named in camelCase

254 views Asked by At

I noticed that in many examples datomic attributes are named using camel case (for example startMonth instead of start-month in mbrainz schema: https://github.com/Datomic/mbrainz-sample/blob/master/schema.edn#L78) which would definitely be more Clojure idiomatic. Why is this so?

Only explanation that comes to mind is that camel case looks more familiar if used from e.g. Java. Is this the reason? Are there any downsides to using kebab-case in Datomic if the db is used from Clojure?

1

There are 1 answers

0
Alan Thompson On BEST ANSWER

As in Clojure itself, the naming convention (camelCase, snake_case, or kebab-case) is up to the user.

A large part of the target market for Datomic is Java users, and many of the docs therefore use Java convention. Other parts of the docs and libraries like Tupelo Datomic use Clojure convention.