protected function registerClientEvents($sliderVarName = null)
    {
        if (!empty($this->clientEvents)) {
            $js = [];
            foreach ($this->clientEvents as $event => $handler) {
                $js[] = "$sliderVarName.noUiSlider.on('$event', $handler);";
            }
            $this->getView()->registerJs(implode("\n", $js));
        }
    }
protected function registerClientEvents($sliderVarName = null)
    {
        if (!empty($this->clientEvents)) {
            $js = [];
            foreach ($this->clientEvents as $event => $handler) {
                $js[] = "$sliderVarName.noUiSlider.on('$event', $handler);";
            }
            $this->getView()->registerJs(implode("\n", $js));
        }
    }
protected function registerClientEvents ( $ sliderVarName = null ) { if ( ! empty ( $ this -> clientEvents ) ) { $ js = [ ] ; foreach ( $ this -> clientEvents as $ event => $ handler ) { $ js [ ] = "$sliderVarName.noUiSlider.on('$event', $handler);" ; } $ this -> getView ( ) -> registerJs ( implode ( "\n" , $ js ) ) ; } }
Registers the events of the slider.

@param string $sliderVarName the JS variable name of the slider element.
Registers the events of the slider .