This repository was archived by the owner on Jul 29, 2025. It is now read-only.

Description
There are currently 2 different implementations of removeClass:
removeClass: (className: string) => {
const classList = new Set(this.state.classList);
classList.delete(className);
this.setState({classList});
},
AND
removeClass: (className: string) => {
const {classList} = this.state;
classList.delete(className);
this.setState({classList});
},
The difference being creating a new Set(). We should not be altering state directly, which is why we create new Set. addClass should also follow this pattern.
Related https://github.com/material-components/material-components-web-react/pull/792/files#r271249191