Correct way to dismiss keyboard from a TextView in Nativescript
<p>I have the following TextView:</p>

<pre><code>&lt;TextView id="textFieldBody" hint="Some hint" text="{{  }}" editable="true" class="TextField" returnKeyType="done" /&gt;
</code></pre>

<p>I'm trying to correctly implement it so that:</p>

<ul>
<li>when the user presses "Done", the keyboard disappears </li>
<li>when the user touches outside (blur) of the TextView, the keyboard
disappears</li>
<li>maybe when focus on the TextView, scroll up so that the rest of the
view doesn't disappear behind the keyboard? (not sure yet about this
one)</li>
</ul>

<p>It's unclear to me how to achieve that. What kind of backend code do I need to implement?</p>

<p>Ideally, I'm looking for a solution that works for both iOS and Android.</p>