<p dir="auto"><strong>I'm submitting a ...</strong>  (check one with "x")</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[x] bug report
[x] feature request"><pre class="notranslate"><code class="notranslate">[x] bug report
[x] feature request
</code></pre></div>
<p dir="auto"><strong>Current behavior</strong><br>
There are <code class="notranslate">markAs</code> methods that can manipulate a form's internal validation state. These are highly useful. However, they propagate to children only sometimes.</p>
<p dir="auto">The following methods also mark their children:<br>
<code class="notranslate">markAsUnTouched</code><br>
<code class="notranslate">markAsPristine</code></p>
<p dir="auto">These methods do <strong>not</strong> mark their children:<br>
<code class="notranslate">markAsTouched</code><br>
<code class="notranslate">markAsDirty</code></p>
<p dir="auto">I'm not even sure what this method is for...<br>
<code class="notranslate">markAsPending</code></p>
<p dir="auto"><strong>Expected behavior</strong><br>
All methods to mark validation should interact with their groups either always or optionally.</p>
<p dir="auto">Alternatively, some basic iteration machinery should be introduced so that we may instrument our own state changes easily.</p>
<p dir="auto"><strong>What is the motivation / use case for changing the behavior?</strong><br>
For example; I want to show validation when loading a record from the DB but I would prefer not to show validation when creating a new record. It would be convenient to to mark everything as dirty or at least touched (as my validation would key off of those states) at the form level.</p>
<p dir="auto">Conceptually, considering the semantic meaning of <code class="notranslate">FormGroup</code>, it seems if a parent control is marked as dirty that would indicate the children are dirty as well. The same reasoning which was originally used to implement <code class="notranslate">reset()</code> and the other <code class="notranslate">markAs</code> functions that handle their children.</p>
<ul dir="auto">
<li><strong>Angular version:</strong> 2.0.0</li>
<li><strong>Browser:</strong> all</li>
<li><strong>Language:</strong> all</li>
</ul>
<p dir="auto">It would be nice to have the possibility to explicitly call a <strong>.validate()</strong> method on a ControlGroup.<br>
Starting with an invalid form just because the user still hasn't entered anything isn't always ideal.</p>
<p dir="auto">In <a href="https://angular.io/docs/ts/latest/guide/forms.html" rel="nofollow">your forms guide</a> it's quite convenient to start out with a populated model, hence you don't need to check !field.dirty or !field.touched in the view.</p>
<p dir="auto">Please see my <a href="https://youtu.be/T__VppOCk04" rel="nofollow">video</a> or check out my <a href="https://github.com/ajtowf/ng2_play">ng2_play repo</a>, it's always easier to show the problem.</p>