thangngoc89 / bsdoc

πŸ“š Documentation Generator for BuckleScript

Home Page:https://ostera.github.io/bsdoc

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

bsdoc

Documentation Generation for BuckleScript projects

Build Status

Read more in the docs: BsDoc

Usage

Install in your project using npm or yarn:

$ yarn add bsdoc@6.0.0-alpha
yarn add v1.12.3
[1/4] πŸ”  Resolving packages...
[2/4] 🚚  Fetching packages...
[3/4] πŸ”—  Linking dependencies...
[4/4] πŸ“ƒ  Building fresh packages...
success Saved lockfile.
warning example@0.1.0: No license field
warning "bsdoc" is already in "devDependencies". Please remove existing entry first before adding it to "dependencies".
success Saved 1 new dependency.
info Direct dependencies
└─ bsdoc@6.0.0-alpha
info All dependencies
└─ bsdoc@6.0.0-alpha
✨  Done in 6.68s.

And whenever you want to generate your docs you can run:

# Build your docs!
MyProject $ yarn run bsdoc build MyProject
yarn run v1.12.3
$ ./node_modules/.bin/bsdoc build MyProject
info: Compiling documentation for package "MyProject"...
info: Generating .html files...
info: Done βœ…
✨  Done in 0.58s.

Additionally, to install the support files (default CSS and Javascript), you can run:

# Create the support files
MyProject $ yarn run bsdoc support-files
yarn run v1.12.3
$ ./node_modules/.bin/bsdoc support-files
info: Copying support files (CSS, JS) into ./docs
info: Done βœ…
✨  Done in 0.53s.

Contributing

bsdoc is developed as a Native Reason project, and is only possible thanks to esy, dune, and, naturally, odoc.

If you haven't installed Esy yet, follow the isntructions in their web site: https://esy.sh

After you have done that, you need only run esy build to get the project bootstrapped.

Installing on Linux/Windows

Unfortunately I haven't gotten around publishing bsdoc for Linux/Windows, but if you have npm installed you can run:

$ esy build
$ esy npm-release

And that'll get you an npm package that you can then install locally (or globally) in any of your projects. Be mindful that it'll only work for bs-platform@6 projects!

About

πŸ“š Documentation Generator for BuckleScript

https://ostera.github.io/bsdoc


Languages

Language:OCaml 77.4%Language:HTML 21.9%Language:Shell 0.7%