Angular 2 Reactive Forms Editing Model
<p>I'm currently working with Angular 2's Reactive Forms module, and I have a question about best practices for editing objects. </p>

<p>I know that you can set initial values when creating a form, such as this: </p>

<pre><code>this.clientForm = this.formBuilder.group({
            name: ['', Validators.required],
            industry: ['', Validators.required]
        });
</code></pre>

<p>Where the initial values are blank as desired. However, in my case I have a child component which uses a service which is shared with the parent. When the user selects an entity to edit in the child, it should fill the form in the parent. Right now I'm using a subscription to the service to fill the values into the form, and then change the value in the service when the form changes, like so:</p>

<pre><code>ngOnInit(): void {   
        this.buildForm();
        this.addEditClientSub = this._clientService.getAddEditClient().subscribe(client =&gt; {
            if (client != null) {
                this.clientForm.patchValue(client, { onlySelf: true });
                this.formChangesSub = this.clientForm.valueChanges
                    .subscribe(x =&gt; this._clientService.updateEditClient(this.clientForm.value));
            }   
        }); 
    }
</code></pre>

<p>but I feel like there must be a better way to handle editing with reactive forms? Not many of the articles out there address editing models with these types of forms...</p>

<p>Thanks!</p>