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

Guidance of structure of values #133

Open
jwrosewell opened this issue Sep 23, 2020 · 3 comments
Open

Guidance of structure of values #133

jwrosewell opened this issue Sep 23, 2020 · 3 comments

Comments

@jwrosewell
Copy link

One of the problems that this document is attempting to solve is the unstructured nature of the User-Agent field value. The document does not currently provide sufficient guidance to implementors concerning the structure of each field value. The document should aim to be as explicit as those related to other HTTP header values if it is to be successful in solving this problem.

See this pull request which incorporates experiment feedback and review from interested users and other stakeholders for proposed text changes.

@yoavweiss
Copy link
Collaborator

Any specific example that's missing?

@jwrosewell
Copy link
Author

A modern computer is made up of different components. This includes at least a) the hardware; b) the operating system; and c) the user agent (web browser) or application. Choosing header names that align to these components and then structuring the information in a consistent form to make extracting and using the relevant information simple for as many developers as possible would be the most efficient and easiest approach to the data model and value structure.

@miketaylr
Copy link
Collaborator

I think we've made progress on this issue, at least in so far as I understand it:

https://wicg.github.io/ua-client-hints/#sec-ch-ua-platform now provides SHOULD-level guidance on OS names (it's not a MUST because new platforms can exist).

https://wicg.github.io/ua-client-hints/#sec-ch-ua is pretty well defined now (but wasn't when this issue was filed).

As for https://wicg.github.io/ua-client-hints/#sec-ch-ua-model, I'm not sure how useful guidance will be because models (the hardware in the previous comment) can vary so widely. But perhaps we can provide guidance on the maximum length of such a value (related to #179).

Does that address your concerns @jwrosewell? As far as literal structure of values, sh-string and sh-list are well-defined so that should make consistent parsing possible for developers and other consumers of the info.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants