I’m not sure, that would probably take some library.
If you were building this locally, it would be trivial to include a json file at build time. At runtime it gets a little more complicated, but is still doable, you just need to fetch that file. Since this is codepen, you’ve have to store it somewhere else. The last option would be to make a request to an http service to get the data.
I don’t have time at the moment to dig into it, but this raises alarm bells:
Never mutate state directly. Always call setState. When you mutate state directly, a puppy dies. And more importantly, React gets confused and doesn’t rerender the way you want. The other problem is that a few lines above, you are setting state. But setting state is asynchronous so you have no idea if it will finish before:
let currentQuote = this.state.quote;
let currentAuthor = this.state.author;
So, you don’t know if those will be the old values or the new ones. You should get those values elsewhere, or, better yet, compile all the data and make one setState call for both.