Clipping through XZ plane on range slider

I want to clip my mesh data through XZ plane (along Y-Plane) using range slider.
I saw threejs example of clipping.

I tried that functionality but not able to clip the mesh through range slider.
But able to clip that mesh using dat.gui folder.
I send the screenshot which i want ,
Please give me suggestion .

Are you looking for something like this?

After defining the markup of your slider, do this in your JavaScript:

const slider = document.getElementById( 'slider' );
slider.addEventListener( 'input', ( event ) => {
    const value = parseFloat( );
    localPlane.constant = value * 0.01;
} );
1 Like

Thanks for suggestion!!
Your suggested way solve my slider issue however i am getting cut body by default like this:
But i don’t want section cut body by default.
i want full body by default and only cut it after moving slider.

I want one more suggestion,
i have set min and max value of slider as min bounding box and max bounding of body.
but it is not working properly. refer below image
upper surface is gets cut always.Unable to set min and max value.