/pokemon-tcg

Designing a site to organize my pokemon cards for fun

Primary LanguageTypeScriptMIT LicenseMIT

Pokemon TCG

This project was generated with Angular CLI version 11.2.8. I'm, right now, using the Pokemon TCG API to fetch the information needed (Although I'm actually not using their repository to keep my models). Also, I will be using Firebase as a database, and its storage as a recipient for the CSV files.

The live version of this project can be accessed right here. It is still a WIP.

Deploy to Firebase Hosting

Run firebase deploy --except functions for deploying. Supposedly it should be enough to deploy using only ng deploy because of the @angular/fire dependencies, but it didn't work for me.

So, after some research, I found this stackoverflow link that explains that this behaviour is not expected, and it is a bug, but it could be corrected by simply not deploying the Firebase Functions. I might correct my deploy script eventually, but it is not a priority.

Images

All images used in this project either came from the Pokemon TCG API or were found randomly at the internet. Credits to the authors. [ x, x, x, x, x, x ]

Setting up CORS

Firebase, as in Google, have a very strict CORS policy. To set up the firebase storage to allow downloads from any paths, allowing me to manipulate the files internally and export the CSVs to upload in LigaPokemon, I had to enable the get for all paths. Although you could, if you wanted, enable for only certain paths as well. The step-by-step can be found in: Firebase Storage Docs and GSuit Installation.

The necessary cors.json is already in the repository.