ecma402 icon indicating copy to clipboard operation
ecma402 copied to clipboard

API naming conventions should be documented

Open gibson042 opened this issue 4 years ago • 2 comments

We should explicitly document naming conventions, and maintain them by evaluating new proposals against them.

  • Property names and values should avoid abbreviations.
    • Good examples: "fractionalSeconds", "minimumSignificantDigits"
  • Property names and values that are compound words should combine them using camelCase.
    • Good examples: "signDisplay", "exceptZero"
    • Exception: for values only, nonzero numbers should be expressed as digits (as in "h23")
    • Historical exceptions: "2-digit", "best fit"
  • [open question about "[...]style" vs. "[...]display" for naming high-level configuration properties]

gibson042 avatar Feb 11 '21 20:02 gibson042

Yes. We have a start in https://github.com/tc39/ecma402/blob/master/docs/style-guide.md, and we should expand that document to cover additional conventions.

sffc avatar Feb 11 '21 20:02 sffc

@ben-allen to make a PR adding more of the content from the OP in time to discuss at the October TG2 meeting.

sffc avatar Sep 18 '23 21:09 sffc