title: React Native app - how to use oauth 2.0 and Open ID connect?
body: <p>I've searched and spent so much time wrapping my head around this. Given a <strong>client_id</strong>, <strong>client_secret</strong>, <strong>authorization_endpoint</strong>, <strong>auth URL</strong>, <strong>token_endpoint</strong> and a few other info-- </p>
  
  <p>*</p>
  
  <ol>
  <li>How do I do connect to get an auth token via ajax call? </li>
  <li>And when I receive the JWT, how do I parse it?</li>
  </ol>
  
  <p>*</p>
  
  <p>There are libraries like <a href="https://github.com/maxmantz/redux-oidc" rel="nofollow noreferrer">redux-oidc</a> available, but doesn't look like its compatible in a react-native app (ran into a rabbit hole of errors).</p>
  
  <p><a href="https://www.npmjs.com/package/react-native-jwt" rel="nofollow noreferrer">react-native-jwt</a> upon basic import on my react-native app, gives me an undefined split() error.</p>
  
  <p>More info: I use redux-saga for middleware.</p>
  
  <p>Hoping somebody can help me, even leads would be truly appreciated.</p>