Show raw api
{
"functions": [
{
"name": "Add",
"desc": "Adds the remote function mixin to a class\n\n```lua\nlocal BaseObject = require(\"BaseObject\")\n\nlocal Bird = setmetatable({}, BaseObject)\nBird.ClassName = \"Bird\"\nBird.__index = Bird\n\nrequire(\"PromiseRemoteEventMixin\"):Add(Bird, \"BirdRemoteEvent\")\n\nfunction Bird.new(inst)\n\tlocal self = setmetatable(BaseObject.new(inst), Bird)\n\n\tself:PromiseRemoteEvent():Then(function(remoteEvent)\n\t\tself._maid:GiveTask(remoteEvent.OnClientEvent:Connect(function(...)\n\t\t\tself:_handleRemoteEvent(...)\n\t\tend)\n\tend)\n\n\treturn self\nend\n```",
"params": [
{
"name": "class",
"desc": "",
"lua_type": "{ _maid: Maid }"
},
{
"name": "remoteEventName",
"desc": "",
"lua_type": "string"
}
],
"returns": [],
"function_type": "method",
"source": {
"line": 40,
"path": "src/remoting/src/Shared/PromiseRemoteEventMixin.lua"
}
},
{
"name": "PromiseRemoteEvent",
"desc": "Returns a promise that returns a remote event",
"params": [],
"returns": [
{
"desc": "",
"lua_type": "Promise<RemoteEvent>"
}
],
"function_type": "method",
"source": {
"line": 54,
"path": "src/remoting/src/Shared/PromiseRemoteEventMixin.lua"
}
}
],
"properties": [],
"types": [],
"name": "PromiseRemoteEventMixin",
"desc": "Intended for classes that extend BaseObject only",
"source": {
"line": 5,
"path": "src/remoting/src/Shared/PromiseRemoteEventMixin.lua"
}
}