Skip to content
This repository has been archived by the owner on Jun 29, 2023. It is now read-only.

New Component Checklist

Katy Robinson edited this page Apr 21, 2020 · 8 revisions
  • Component follows boilerplate structure
    • Interfaces are in interfaces.ts
    • Slots documented at top of file
    • Props are properly reflected or mutated
    • Props are documented
    • UI text props start with intl
    • Events start with calcite**COMPONENT**
    • Props without values are marked as required or optional. (? or !)
    • Name of Props, Methods, Events are consistent with other components.
    • Internal events are not propagated
  • Rendering consistency
    • JSX nodes are semantic and aria roles are present if necessary
    • classnames utility used for multiple classes
    • setFocus method is present if component needs to be focused.
    • RTL support is present if necessary
    • Keyboard events are preventDefault() as necessary.
    • MutationObserver is used accordingly to re-render.
  • Resources file with CSS, ICONS, TEXT and SLOTS constants
  • Readme.md with description of component
  • Stories with knobs
  • Usage md file(s)
  • e2e test(s) and unit test(s)
    • Render test
    • Accessibility test(s)
    • hidden attribute test
  • For consistent naming, look at other components to see if there's an existing property/method/event name to follow.