It's a simple blog application that allows users to create, read, update, and delete blog posts. The application is built using Vue 3, Vite, and Firebase. The Firebase SDKs include Firebase Authentication, Firestore, and Firebase Storage. Finally, it uses Firebase hosting to deploy the application.
.env.localfile is required to publish a blog(i.e., checking whether you're the admin or not). Add the following environment variables:
VITE_APP_ADMINEMAIL=<your_email>
-
Create a Firebase project and enable Firestore, Firebase Authentication, and Firebase Storage. Change the setup in the
shared/firebase/firebase-config.tsfile. It includes the document collection name and the storage bucket name. -
Remove the GTM configuration in the
index.htmlfile, or change it to your GTM configuration.
npm installto install dependenciesnpm run devto start the development servernpm run buildto build the application- Please check out the files in
.github/workflowsto see how to deploy the application to Firebase hosting with GitHub actions
- Apology that I prefer to use the kebab-case for the file naming convention rather than the PascalCase.
- The
app.vuefile is the main entry point of the application with therouter-viewonly. Depending on the route, the corresponding component will be rendered. - The
routes.tsfile contains the routes of the application. All routes are lazy-loaded.