Skip to content

logseq/clj-fractional-indexing

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

clj-fractional-indexing

This is a Clojure port of the original JavaScript implementation https://github.com/rocicorp/fractional-indexing.

Usage

(require '[logseq.clj-fractional-indexing :as index])

;; Generate one key

(index/generate-key-between nil nil)
;; "a0"

(generate-key-between "a0" nil)
;; "a1"

(generate-key-between "a0" "a1")
;; "a0V"

;; Generate multiple keys
;; ["a0G" "a0V" "a0l"]

License

Distributed under the Eclipse Public License version 1.0.

About

Fractional Indexing in Clojure/Clojurescript

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published