💬 RFC: add onboarding docs geared at newcomers to web components or JS framework devs, to fast.design #6638
Labels
closed:answered
An answered question
community:noteworthy
An issue or PR of particular interest to the community or planned for an announcement.
docs:rfc
Request for Comments (proposal)
Context
This request comes about from discussions I’ve had with @rajsite on the steep learning gradient Javascript framework developers who may also be new to web components experience when onboarding to use FAST.
I propose collaborating on a documents to address the following topics with the goal of:
The following are topics I suggest adding articles, codeblocks or tutorials for are a result of common questions I've received from onboarding teams of 5-20 at work to contribute components to a design system built with
"@microsoft/fast-element": "2.0.0-beta.18"
and"@microsoft/fast-foundation": "3.0.0-alpha.22"
Related Discord threads: 1, 2, 3, 4
Related: #6527 but Rob asked me to create a RFC to track this.
Potential Topics
What are web components and what does FAST have to do with it?
@customElement
directive?How FAST accelerates component development instead of writing vanilla JS web components
@observables
instead ofstatic getObservedAttributes()
@attr
to define (custom) attributes to make them available on the custom element markup levelwhen
,ViewTemplates
and@observable
slotted
directive, and the role ofdefaultSlottedContent
property in existing FAST components andFASTElement
, and how that impacts component architectureconnectedCallback()
inFASTElement
that require callingsuper()
in extended components to leverage inherited class methods.How do event lifecycles in FAST differ from handling events in Angular or React?
Example Stackblitz showing:
super.<inheritedMethod>()
in a class method@<event>
syntaxFASTButton
$emit
for dispatching custom events within the light DOM.How to prepare form field components so that work inside a form element?
Example Stackblitz demonstrating preparation of Text Field as a Form Associated Custom Element. Related: Add form-associated components documentation. #3536
To Be Offered:
Other lifecycle topics:
Updates.enqueue()
to queue the application of changes on re-rendersConfiguring FAST components to close or disable the Shadow DOM/ only support Light DOM
Example: article and Stackblitz with
fast-foundation
components to prototype these attempts in "Closing, Cloning, or Disabling the Shadow DOM"Note: I know there is already advice on the doc site, but the above subject came up so much at work in comparison with Stencil with all-or-nothing ideas about implementing components with shadow DOM; I believe we could supply explainers of the implications of “disabling” or “closing” the shadow DOM and offer ways to work with event emitting or scoping styles for shadow DOM instead
💻 Examples
The following typologises existing industry examples of onboarding JS developers to onboard, adopt or migrate frameworks:
The FAQ style page:
The Framework Comparison:
<div> riots
, Feb 17, 2022.Conceptual Translations
Familiar mental models that developers comfortable with non-web-component frameworks can use to ramp up faster:
The tutorial series with code clips:
The Table-of-contents for Incremental Code-along Learning
Recommended Testing Integrations
The text was updated successfully, but these errors were encountered: