angular / angular/components

[Docs] More details on custom form field controls guide

Ouverte
#13,624 6 commentaires 2 réactions 0 personnes assignées Voir sur GitHub
area: docs area: material/form-field help wanted P3
Langage dominant
TypeScript
Étoiles
25k
Forks
6.8k
Merge moyen
1 j 8 h
PR mergées (30 j)
91

Description

#### Bug, feature request, or proposal:
I'd like to request a review of the 'Creating a custom form field control' guide as it does not cover enough in regards to each of it properties and opts to just mentioning them.

#### What is the expected behaviour?
Common examples that are detailed on other approaches and usages.

#### What is the current behaviour?
Common examples that are not all detailed on other approaches or usages.

#### What is the use-case or motivation for changing an existing behaviour?
My biggest gripe that pushed me to make this ticket is that of the error state.

> Since we're not using an NgControl in this example, we don't need to do anything other than just set it to false.

Where as it should be like 'ngControl' which has sufficient methods of implementation

> It is likely you will want to implement ControlValueAccessor ...

#### Is there anything else we should know?
Others have had the same issue

https://stackoverflow.com/questions/52017000/angular-material-custom-reactive-form-control-with-error-state/52017769

Guide de contribution

Ouvrir le guide de contribution

Piste de recherche

Commencez par lire le guide « Creating a custom form field control » et comparez ses descriptions de propriétés avec les exemples demandés et la discussion sur l’état d’erreur. Le travail est considéré comme terminé lorsque le guide explique les utilisations courantes des propriétés, présente des approches pertinentes et clarifie la gestion de l’état d’erreur ainsi que le contexte de ControlValueAccessor.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
angular, typescript
Domaine
documentation
Type d'issue
Documentation
Difficulté
3/5
Temps estimé
1-2 jours
Activité
À l'abandon
Clarté
Plutôt claire
Accessibilité débutants
35/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.