package node_of_ocaml
An OCaml ppx to require node modules
Install
Dune Dependency
Authors
Maintainers
Sources
1.0.0.tar.gz
md5=31e966a5e495d7f5a76d65d0bed65d49
sha512=91bd1184132a497491db55b460da27f8fa7301aabe8c2034ab404e2f15d6baa821bcfe4c4bb14e972602a907f24d57075de2fd80807c45ec16e97402022a5a24
README.md.html
node_of_ocaml
This is a simple OCaml ppx rewriter to use node modules in OCaml.
Install
opam install node_of_ocaml
Usage
In your dune
file:
(executable
(name <exe_name>)
(modes js)
(preprocess (pps node_of_ocaml)))
If you wish to use a node module, just use this:
let uniq = [%require uniq]
To use the compiled file in your browser you cin use your favorite JavScript bundler.
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>