Skip to content

Remove blocklisted classes from autocomplete #10844

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Mar 23, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Don't unnecessarily loop over classes
Co-authored-by: Robin Malfait <malfait.robin@gmail.com>
  • Loading branch information
thecrypticace and RobinMalfait committed Mar 23, 2023
commit 3332eb620a0fc6b4269e68e2fcfca5d335640aac
4 changes: 3 additions & 1 deletion src/lib/setupContextUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -1008,7 +1008,9 @@ function registerPlugins(plugins, context) {
}

// Exclude utilities that are known non-classes (e.g. from the blocklist)
output = output.filter((cls) => !context.notClassCache.has(cls))
if (context.notClassCache.size > 0) {
output = output.filter((cls) => !context.notClassCache.has(cls))
}

return output
}
Expand Down