Custom Polyfills
Advanced users might want to replace the default standard library polyfills (for bit32, string, etc.) with their own implementations.
Configuration
Section titled “Configuration”You can specify a custom polyfill source in kaledis.toml.
From Git
Section titled “From Git”[polyfill]location = "https://github.com/my-user/my-polyfill"From Local Path
Section titled “From Local Path”[polyfill]location = "./my-local-polyfill"Structure
Section titled “Structure”A custom polyfill folder usually contains a custom_polyfill.toml (or similar, depending on implementation) and the lua files that implement the required functions. you can look for an example at: https://github.com/CavefulGames/dalbit-polyfill
Troubleshooting
Section titled “Troubleshooting”- Missing functions: If your game crashes with errors like
attempt to call field 'band' (a nil value), your custom polyfill might be incomplete. Ensure you implement all Luau standard library functions used by your code/dependencies. - Version mismatch: If updating Kaledis, check if the expected polyfill interface has changed.