toggle method

bool toggle(
  1. String token, [
  2. bool force
])

The toggle() method of the DOMTokenList interface removes an existing token from the list and returns false. If the token doesn't exist it's added and the function returns true.

Implementation

external bool toggle(
  String token, [
  bool force,
]);