Git Product home page Git Product logo

blogify-app's Introduction

Blogify App

Blogify is a simple tool for users to write, edit and share technical/non-technical blogs with their respective audiences.

Idea

Idea is to build a subset of what Hashnode does for the dev community.

PRD

MVP

  • As a user, I should be able to create blogs with unique URL [DONE]
  • As a user, I should be able to edit blogs [DONE]
  • As a user, I should be able to view all available public blogs [DONE]

V1

  • As a user, I should be able to signup/login with google as IDP [Auth] [Done]
  • As a user, I should be able to signup/login with GitHub as IDP [Auth] [Done]
  • As a user, I should be able to signup/login with Facebook as IDP [Auth] (optional)

V2

  • As a user, I should be able to view all my past blogs
  • As a user, I should be able to like, share, and comment on blogs
  • As the author of the post, I should be able to reply to comments on blogs

EDD (Engineering design document)

Tech Stack

We will be using the following technologies as part of bootstrapping our application:

  • NextJS with API routes
  • Firebase Auth (for user authentication)
  • Firestore (for storing user blogs)
  • Docker (to containerize Next App)
  • Cloud Run (host containerized app with minimal configuration)
  • Firebase Auth prebuilt UI
  • Flowbite React UI Components for quick bootstrapping over tailwind built components
  • Editor: TipTap

Firestore Schema

  1. Users collection: /users/{id}, to keep track of logged in users (shall be updated on functions.auth.user().onCreate side effect to sync users in firestore automatically myBlogs Blogs: Comments Replies Likes Views

Note: Below mentioned is a schema, which is good to start with w.r.t maintaining data for users, user’s blogs and some future functionalities supporting comments, replies, likes and views.

Firestore structure

Security

Client: For authentication for client-side users, we will use Firebase auth (via google/signin anonymously and github as IDP) Third party users: For Exposing APIs: For each route we can setup custom CORS handler with allowable methods (GET, PUT, POST, DELETE) We can accept API_SECRET_KEY on middleware to handle third party authentication

Project Timeline

  • Dockerized Next Application
  • Added Deploy script to automatically deploy to cloud run with one single CLI command
  • Started Thinking about what I should build, and I chose Blogs :p, I wanted to create a blogging website for so long
  • Created Firestore Schema in draw.io
  • Added Firebase Auth in App, with Google and Github as IDP
  • Added Firebase Auth Prebuilt UI, faced some issues with React wrapper over Firebaseui
  • Focused on Adding FirebaseAuthProvider in one of the best possible way in code (afaik)
  • Focused on completing signin/signout
  • Decided to use some UI kit (flowbite) to speed up development
  • Started working on Integrating Firestore with App
  • Integrated POST API route with App, to create post
  • Added logic for creating/editing Blogs from UI
  • Decided to use TipTap as Editor Engine, as it is one of the best editors out there
  • Tested stuff e2e

Code Structure

References

https://itnext.io/create-a-front-app-immediately-with-next-js-on-google-cloud-run-d0cfde795ce3 https://github.com/vercel/next.js/tree/canary/examples/with-docker

blogify-app's People

Contributors

abhidtu2014 avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.