In Process the Result, we specify "Methods should avoid a return type whenever possible."
This is not sufficiently clear.
Samples should not return values as part of presenting how to work with the API response. Instead, they should output meaningful properties from the response object to teach developers how to work with the response, and confirm for folks running the code that it works as expected.
This is clarifying a generally understood sample guideline amongst existing sample contributors, and help clarify the expectation for folks onboarding to samples.
Challenge
This is a clarification of the existing guideline.
Description
In Process the Result, we specify "Methods should avoid a return type whenever possible."
This is not sufficiently clear.
Samples should not return values as part of presenting how to work with the API response. Instead, they should output meaningful properties from the response object to teach developers how to work with the response, and confirm for folks running the code that it works as expected.
A PR to address better code examples has been opened, which addresses #135, #136, #137, but not the main guideline text.
Impact
This is clarifying a generally understood sample guideline amongst existing sample contributors, and help clarify the expectation for folks onboarding to samples.
Challenge
This is a clarification of the existing guideline.