How to fix cookies not persisting using CORS

I have been toying around with React to refresh my frontend skills (The last time I used full stack seriously was with backbone.js 😂). W