If the code being formatted contains a comment anywhere in it like:
// dart format width=123
Then the code is formatted at that width instead of the default width.
The intent is that tools that generate code and then format it will put this comment in the generated code. That way, the tool doesn't have to handle the complex logic to find a surrounding analysis_options.yaml file and get the user's project-wide page width configuration.
End users may also want to use this comment in rare cases. For example, maybe they have a library that contains a large value of data that looks better as a big wide table but they don't want their entire project to have a wider page width.
If the code being formatted contains a comment anywhere in it like:
Then the code is formatted at that width instead of the default width.
The intent is that tools that generate code and then format it will put this comment in the generated code. That way, the tool doesn't have to handle the complex logic to find a surrounding analysis_options.yaml file and get the user's project-wide page width configuration.
End users may also want to use this comment in rare cases. For example, maybe they have a library that contains a large value of data that looks better as a big wide table but they don't want their entire project to have a wider page width.