title: How to do React Native app once the user logs in, then it should be automatically logged in?
body: <h1>login request from API</h1>
  <p>How to do React Native app once the user logs in, then it should be automatically logged in?
  Once logged into the application, it should automatically be able to log in every time.</p>
  <pre><code>export default class LoginForm extends Component {
    state = {
      email: &quot;&quot;,
      password: &quot;&quot;,
      login: false,
    };
    uri = Info.BaseUri + Info.LoginEndPoint;
    # login request from API #
    login = () =&gt; {
      fetch(this.uri, {
        method: &quot;POST&quot;,
        headers: {
          Accept: &quot;application/json&quot;,
          &quot;Content-Type&quot;: &quot;application/json&quot;,
        },
        body: JSON.stringify({
          identifier: this.state.email,
          password: this.state.password,
        }),
      })
        .then((response) =&gt; response.json())
        .then((data) =&gt; {
          if (data.user.email == this.state.email) {
            saveUser(data.jwt, data.user);
            this.props.navigation.navigate(&quot;Home&quot;);
          }
        })
        .catch(() =&gt; {
          alert(&quot;Email adresi veya parola hatalı!&quot;);
        });
    };
  </code></pre>