MCPcopy Create free account
hub / github.com/angular/components / toggle

Method toggle

src/material/slide-toggle/slide-toggle.ts:295–298  ·  view source on GitHub ↗

Toggles the checked state of the slide-toggle.

()

Source from the content-addressed store, hash-verified

293
294 /** Toggles the checked state of the slide-toggle. */
295 toggle(): void {
296 this.checked = !this.checked;
297 this._onChange(this.checked);
298 }
299
300 /**
301 * Emits a change event on the `change` output. Also notifies the FormControl about the change.

Callers

nothing calls this directly

Calls 1

_onChangeMethod · 0.80

Tested by

no test coverage detected