Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
public componentDidMount() {
super.componentDidMount();
if (this.control) {
this.MDComponent = new MDCSlider(this.control);
this.MDComponent.listen('MDCSlider:change', this.onChange);
this.MDComponent.listen('MDCSlider:input', this.onInput);
}
this.setValue(this.props.value); // set initial value programatically because of error if min is greater than initial max
}
installed() {
const slider = new MDCSlider(_.base)
slider.listen('MDCSlider:change', () => {
_.props.onChange && _.props.onChange(slider.value)
})
}
})
installed() {
const slider = new MDCSlider(this.shadowRoot.querySelector('.mdc-slider'));
slider.listen('MDCSlider:change', () => {
this.fire('change', { value: slider.value })
});
}