Package Exports
- @rbxts/janitor
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@rbxts/janitor) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
@rbxts/janitor
Typings for pobammer's forked janitor module
Credits to Validark for the original module, see RoStrap's Janitor docs for more information.
Changes
- Gets the Promise lib by using _G
- Returns
return {
Janitor = Janitor
}instead of just returning the Janitor namespace.
Changelog
1.0.2
- Simplified
Addtypes - Credited Validark
1.0.1
- Fixed
README.md
1.0.0
- Initial release
Installation:
npm i @rbxts/janitor
Example Usage
import janitor from "@rbxts/tableutil";
const Obliterator = Janitor.new();
// Queue the Part to be Destroyed at Cleanup time
Obliterator.Add(new Instance("Part"), "Destroy");
// Queue function to be called with `true` MethodName
Obliterator.Add(print, true);
// By passing an Index, the Object will occupy a namespace
// If "Instances" already exists, it will call :Remove("Instances") before writing
Obliterator.Add(new Instance("Part"), "Destroy", "Instances");