package vcaml
OCaml bindings for the Neovim API
Install
Dune Dependency
Authors
Maintainers
Sources
vcaml-v0.16.0.tar.gz
sha256=dd123302c46af7ca6eda8a7806c78236fd217a8c73a2e1cd7da85f1d69ed1ae4
doc/vcaml.msgpack_rpc/Msgpack_rpc/index.html
Module Msgpack_rpc
Source
Implements the Msgpack RPC protocol. See https://github.com/msgpack-rpc/msgpack-rpc/blob/master/spec.md
Although you can still subscribe after the RPC is connected, note that if you do you may miss events sent before the subscription.
Source
val register_method :
_ t ->
name:Base.string ->
f:(Msgpack.t Base.list -> Msgpack.t Async_kernel.Deferred.Or_error.t) ->
[ `Ok | `Duplicate ]
Although you can still register methods after the RPC is connected, note that if clients call the method before registration they will see an error for an undefined method.
Source
val connect :
[ `not_connected ] t ->
Async.Reader.t ->
Async.Writer.t ->
close_reader_and_writer_on_disconnect:Base.bool ->
[ `connected ] t
Once connect
is called the counterparty can start calling methods and sending notifications. Any methods that should be callable at that time should be registered beforehand, as should any subscriptions to the event bus. Calling connect
twice will raise.
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>