Directive to auto save input field
npm install form-save-pluginSimple Plugin to auto save and restore Input field in Angular
Used ViewChildren to get the QueryList of elements or directives from the view DOM. Any time a child element is added, removed, or moved, the query list will be updated, and the changes observable of the query list will emit a new value.
Save directive has the method to save the value inside the view DOM Input field to a JSON.
All these fields are restored on click of a button.