Skip to content

rachael-mcbride/code-by-heart-app

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

91 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Code by Heart

Introduction

Code By Heart is a full-stack flashcard app that lets users create and save decks of flashcards, then review them at optimally spaced intervals using the SM-2 spaced repetition algorithm (learn more). Flashcards can be either plain text or runnable code snippets, supporting 15+ programming languages, including Python, JavaScript, Go, C++, C, C#, Objective C, Ruby, Java, Scala, Swift, Rust, Kotlin, and Elixir.

Demo

github-demo-2022.mp4

Installation

Backend

Firebase Authentication

  1. Create a Firebase project for Code By Heart.
  2. Enable Google Sign-In and add your local host as an authorized domain.
  3. Update src/firebase/firebase.utils.js with your Firebase API key after cloning the backend repo. Note: Firebase API keys are safe to expose publicly (reference).

Backend

  1. Clone this backend repo.
  2. Create and activate a virtual environment (python3 -m venv venv and source venv/bin/activate), and install dependencies.
  3. Get a free JDoodle API key (jdoodle.com) and create a .env file with:
JDOODLE_CLIENT_ID=your_client_id
JDOODLE_CLIENT_SECRET=your_client_secret
  1. Create a local PostgreSQL database named code_by_heart and add the connection string to .env: SQLALCHEMY_DATABASE_URI=postgresql+psycopg2://<user>:<password>@localhost:5432/code_by_heart
  2. Initialize and migrate the database.
  3. Run the backend: flask run.

Frontend

  1. Clone this frontend repo.
  2. Install dependencies.
  3. Create a .env file with your backend URL.
  4. Start up the frontend: yarn start.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors