Page MenuHomePhabricator

Define boundaries on when a component becomes part of the library or built as one-off
Closed, ResolvedPublic


Define boundaries on balancing when components are added to the library versus being “standalone”, built as “one-off” component.
Compare decision point in Governance model.

Things to consider:

  • General application possible (example: button) versus specific to one context, one team, one problem
  • Being an addition, a variant to an existing component vs. single component

Decision guardrails to above:

  • Possible performance impact on library (eventually countered with entry points to the library, compare T280828 or longer-term abilities like tree-shaking)
  • Possible maintenance burden on DS team, not on feature team, ever-growing backlog

Event Timeline

On component being part of the main library vs project-specific development:
In OOUI, we've followed a process of having added components that are only used in one product without general application become part of the product, not the library.
There have also been some components in long past, that started as product-specific components and have then be evened out their edges to be generalized as much as possible. TagMultiselectWidget is the most recent example, being added to OOUI for RCFilters and then be used on a number of products.

For the coming Vue.js shared library we're set out to ensure a design-first approach where not one product team, but all product teams including WMDE teams are informed about all component development and invited to participate in it. The component prioritization is currently done around product migration prios. Additionally it's pretty clear that all basic components, similar to OOUI's core widgets, will probably tackled with priority as they are needed for many interfaces to construct.

An additional angle for adding to the main library is performance and possible entry points for a shared library similar to what was discussed in T280828.

Volker_E renamed this task from Define boundaries on when a component becomes part of the library or building on top to Define boundaries on when a component becomes part of the library or built as one-off.Aug 17 2021, 2:58 PM
Volker_E updated the task description. (Show Details)

One point that was raised in the summit (apologies I forgot who specifically raised this point) was where and how people could see what one-off components are available. I wonder if there is a case to be made for documenting all one-off components in the same place? This may help surface when one-offs could be elevated and reduce redundancy in people potentially starting work to propose a new component for which a one-off already exists.

egardner claimed this task.
egardner subscribed.

Closing this task because I believe it has been superseded by more recent team process work.