Related Resources
-
Online Playground – Run Rhai scripts directly from an editor in the browser
-
Language Server – Experimental Language Server Protocol (LSP) server for Rhai
-
rhai-doc– Rhai script documentation tool
-
VS Code Extension – Support
.rhaiscript files syntax highlighting for Visual Studio Code. -
JetBrains Plugin – Support
.rhaiscript files syntax highlighting and more for JetBrains IDE’s. -
Sublime Text 3 Plugin – Support
.rhaiscript files syntax highlighting for Sublime Text 3. -
Vim Plugin – Support
.rhaiscript files syntax highlighting for Vim. -
For other syntax highlighting purposes, e.g.
highlight.js, both Rust or JavaScript can be used successfully.Use
rustwhen there is no string interpolation. This way, closures and functions (via thefnkeyword) are styled properly. Elements not highlighted include:- strings interpolation
- the
switch,importandexportstatements - the
thisandprivatekeywords - built-in functions such as
Fn,call,type_of,is_shared,is_def_var,is_def_fn
Use
js(JavaScript) when there is strings interpolation. Elements not highlighted include:
-
ChaiScript – A strong inspiration for Rhai. An embedded scripting language for C++.
-
Check out the list of scripting languages for Rust on awesome-rust