Skip to content

Latest commit

 

History

History
83 lines (57 loc) · 2.72 KB

README.md

File metadata and controls

83 lines (57 loc) · 2.72 KB

Pinsta

Pinsta is a social media platform that allows users to discover and save ideas for various projects or interests by pinning them to virtual pinboards. It's often used for inspiration, planning, and bookmarking, with content ranging from recipes and fashion to home decor and travel. Here is the live link Pinsta 🖼️

Wiki

Tech Stack

JavaScript HTML5 CSS3 NodeJS Flask React Redux

Database:

Postgres

Hosting:

Render

Run Locally

HTTPS

  git clone https://github.com/ELIxFOSTER/Pinsta.git

SSH

  git clone [email protected]/ELIxFOSTER/Pinsta.git

Install dependencies

pip install -r requirements.txt &&
flask db upgrade &&
flask seed all
cd react-app
npm install --prefix react-app 

Start the server

pipenv run flask run

In seperate terminal

cd react-app
npm start

Landing Page

Cloned Site

Screenshot 2023-03-19 231413

Technical Challenges

Removing a single pin from a board. I passed both the boardId and pinId, looped through all of the boards pins, found the matching id, then popped the pin off the board so that it was just removed not deleted

  def remove_pin(id):

    res = request.get_json()
    pinId = int(res['pinId'])

    data = Board.query.get(id)
    for idx, x in enumerate(data.board_pins):
        if x.id == pinId:
            index = idx


    data.board_pins.pop(index)
    db.session.add(data)
    db.session.commit()