Skip to content

Commit

Permalink
refactor classList.remove since he accept multiple argument (#3092)
Browse files Browse the repository at this point in the history
  • Loading branch information
dimaMachina authored Mar 7, 2023
1 parent 5cf77e0 commit 301f859
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions packages/graphiql-react/src/theme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,7 @@ export function useTheme() {
return;
}

document.body.classList.remove(`graphiql-light`);
document.body.classList.remove(`graphiql-dark`);
document.body.classList.remove('graphiql-light', 'graphiql-dark');
if (theme) {
document.body.classList.add(`graphiql-${theme}`);
}
Expand Down

0 comments on commit 301f859

Please sign in to comment.