A library for moving around a sequence (list/array/tuple) in Janet.
- Add this a dependency in your
project.janet
file and install deps.
(declare-project
:name "my-project"
:description "my project"
:dependencies ["https://github.com/corasaurus-hex/janet-sequence-cursor"])
jpm deps
- Import the module.
(import sequence-cursor :as sc)
- Use!
(def seq (sc/make [:a :b :c]))
(:next seq)
;;# => :a
Check out the tests and the docs on individual functions for more on how to use this.