Type-safe Lua IDE — IntelliJ IDEA plugin
Install from within your IDE's preferences or from the Jetbrains Marketplace.
fun(optionalParam?: number): void
---@param optionalParam? number
{ a: 1 }
, rather than just table
..def.lua
files.@not
.Install from within your IDE's preferences or from the Jetbrains Marketplace.
DebugInfo
class (returned from debug.getinfo
) is now known as std__DebugInfo
and is a shape rather than a class. Fields presence and types have also been corrected.string | number
.fun
(without a parameter list).init
function with different parameters) then you should annotate the parent init
(and child) as @private
.any
.[1]
in arr[1]
.self
type when writing classes as closures i.e. expressions that look like setmetatable(someTable, {__call=function() end})
. In such cases self
type will be resolved based on the return type of __call
.nil
to a member of table<K, nil | V>
self
typed variables.function
type is now treated as returning any...
@overload
in @class
definitions that do not proceed a variable declaration/assignment.Ensured "Return type 'void' specified but no return values found" annotation is no longer raised for functions annotated as ---@return void
.
Same as 1.0.1, but not tied to IntelliJ 201 (2020.1).