Skip to content
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

Provide a list of all supported client hints #298

Open
jridgewell opened this issue Apr 7, 2022 · 2 comments
Open

Provide a list of all supported client hints #298

jridgewell opened this issue Apr 7, 2022 · 2 comments
Labels
enhancement New feature or request

Comments

@jridgewell
Copy link

Similar to PerformanceObserver.supportedEntryTypes, I'm looking for a programatic way to collect a list of all supported client hints that could be requested from getHighEntropyValues.

In Terser, we reserve a list of known keys when mangling so that most users won't have to do any special configuration in order to work with the DOM APIs. Without a list of known client hints (which are used as keys in the return object from getHighEntropyValues, we're stuck maintaining a hardcoded list of current hints. This list is guaranteed to go out of date with new additions, so I'd like to get this maintained as part of the official DOM API.

@miketaylr miketaylr added the enhancement New feature or request label Apr 11, 2022
@miketaylr
Copy link
Collaborator

@jridgewell to clarify, you're interested in a way to know all possible hints, or just the hints supported by a given browser? Looking at terser, it seems like this doesn't run in the client, so possibly the former is what you're after.

@jridgewell
Copy link
Author

Those supported by the current browser. We use a helper page to extract a list of DOM properties automatically.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants