Unexpected token < in JSON at position 0
December 14, 2020 at 7:08amUnexpected token < in JSON at position 0
December 14, 2020 at 7:08amI'm able to purchase a subscription in development and everything seems to work, however, when I deploy to firebase hosting, I get
Unexpected token < in JSON at position 0
when I select a plan. I tried changing the STRIPE_DOMAIN .env variable to match my deployed URL, but I still get this error.
December 14, 2020 at 5:38pm
Hey Brad, did you do anything to prepare your serverless functions (in
/api
) to work with Firebase Hosting? We don't yet support Firebase Hosting out of the box (coming soon). Depending on your export option those functions may be formatted for hosting with Vercel or Netlify. Here's some info on how those functions should be formatted for Firebase and how to deploy: https://firebase.google.com/docs/hosting/functionsIf you need any help making those changes let me know!
December 15, 2020 at 3:43am
(gabe-ragland) thanks for the reply. It makes sense now. Before I go down the path of rewriting the functions for firebase, do you have an ETA on firebase hosting? Thanks
December 15, 2020 at 6:58pm
My estimate is around Feb/March, which I imagine isn't super useful for you.. That said, if you go down the path of rewriting, I'd be happy to help out if you run into any issues. If helpful, feel free to add me a to your github repo or shoot me any questions. My github email is [email protected]