A slime chunk in the middle of your build? Stop covering every floor with carpet or string just to keep those pesky green visitors away. Place a note block, a slime block, and a powered lever to disable natural slime spawning in that chunk. Flip the lever off whenever you want the slimes back.
Disable Slime Chunks is a server-side Fabric mod (also works in single player) that lets players control natural slime spawning in individual chunks using a simple structure made from vanilla blocks.

Build the following vertical structure anywhere inside the chunk you want to control, from bottom to top:
Switch the lever on to disable natural slime spawning throughout that chunk. Switch the lever off to immediately allow natural slime spawning again.
The lever must be floor-mounted on top of the slime block. A lever attached to the side of the slime block does not activate the controller.
The controller blocks naturally spawning slimes, including normal slime-chunk spawning. It does not block slimes created by:
Existing slimes are not removed when a controller is activated.
Feel free to join my Minecraft server to test my mods: play.swordfishbe.eu