TypeScriptToLua plugin that replaces calls to the TSTL delete
function with a statement setting a value to nil
.
This repo offers an alternate implementation to the simplifyDelete
option in gb-tstl-utils.
❗ Use this and any code transformation plugin with caution. Mistakes are possible.
__TS__Delete(x, y)
becomes x[y] = nil
Requires TSTL >= 1.22.0.
- Install this plugin
yarn add tstl-simple-delete -D
# or
npm install tstl-simple-delete --save-dev
- Add
tstl-simple-delete
totstl.luaPlugins
intsconfig.json
{
"tstl": {
"luaPlugins": [
+ {
+ "name": "tstl-simple-delete"
+ }
],
}
}
CC0