Luau Language Server
An implementation of a language server for the Luau programming language.
Install the extension from the VSCode Marketplace or OpenVSX Registry:
For General Users
The language server should be immediately usable for general Luau code after installation.
String require support is provided for module paths, using
Type definitions can be provided by configuring
If there are specific features you require in the language server for your use case, feel free to open an issue.
For Rojo Users
Rojo instance tree and requiring support is provided by default, and the language server should be able to directly emulate Studio.
The extension will automatically populate the latest API types and documentation (which can be disabled by configuring
To resolve your instance tree and provide module resolution, the language server uses Rojo sourcemaps.
The language server will automatically create a
It does this by running the
Note, if you are using the VSCode extension on macOS, you need to configure the location of the Rojo binary at
By default we generate a sourcemap for a
A companion Studio plugin is available to provide DataModel information for Instances which are not part of your Rojo build / filetree: Plugin Marketplace
The tool can run standalone, similar to
Install the binary and run
The initial goal is to develop a language server supporting all common LSP functions. Module resolution and typing will initially revolve around Rojo.
The idea is to ensure module resolution is customisable, allowing the server to later be easily extended to support other environments where Luau may be used. We could also potentially take it a step forward, allowing the server to be used on an Lua 5.1 codebase through a translation layer (such as type comments through EmmyLua), allowing the language server to support general purpose Lua development powered by the Luau type inference engine.
If you use Luau in a different environment and are interested in using the language server, please get in touch!
The following are extra features defined in the LSP specification, but most likely do not apply to Luau or are not necessary. They can be investigated at a later time:
Build From Source