Code Monkey home page Code Monkey logo

countmedown's Introduction

countmedown

Countdown To-Do App

What is the purpose?

This app is a to-do list with a countdown feature. The app allows you to:

  • Enter a task title
  • Enter a task description
  • Enter a completion date
  • Display the time remaining for the task
  • Allow you to delete tasks

Tech Used

This app was built using:

  • Node.js
  • Express
  • MongoDB/Mongoose

Optimizations

Future improvements could include:

  • A way to delete multiple tasks quickly.
  • Ability to reorder tasks either by urgency or completion date.

Lessons Learned

... lessons still loading...

Development environment setup

To initialize your development environment with git:

git clone https://github.com/YOURUSERNAME/countmedown.git

This will make a copy of YOUR fork of the original repo. Change into this directory:

cd /countmedown

In order to be able to fetch changes from the upstream (original) repo to your local repo, do the following:

git remote -v
  • This will show your current remote repo, which should be YOUR repo
origin  https://github.com/YOURUSERNAME/countmedown.git (fetch)
origin  https://github.com/YOURUSERNAME/countmedown.git (push)
  • To add the new upstream, type:
git remote add upstream https://github.com/intelagense/countmedown.git
  • Now if you type:
git remote -v
  • You should see:
origin  https://github.com/YOURUSERNAME/countmedown.git (fetch)
origin  https://github.com/YOURUSERNAME/countmedown.git (push)
upstream        https://github.com/intelagense/countmedown.git (fetch)
upstream        https://github.com/intelagense/countmedown.git (push)
  • Now you may edit the files in your local copy.
  • To push your changes:
git add .
git commit -m 'message'
git push
git fetch upstream
  • To install the necessary npm packages listed in package.json:
npm install

User credentials (use your own mongodb credentials for the time being)

  • Use dotenv module for credential storage on your local machine
  • .env file contains login information, and MUST BE in your .gitignore
  • THIS MUST BE SETUP BEFORE PUSHING TO GITHUB
  • NO pull requests should be allowed that include credentials

Example of dotenv use:

const dotenv = require('dotenv') // .env file
dotenv.config() // using .env
const connectionString = `mongodb+srv://${process.env.USER}:${process.env.PW}@cluster0.bzzkg.mongodb.net/?retryWrites=true&w=majority`;

Example of file ".env" (this file is in your project root folder): (plain text file, full name .env)

Be sure to use the quotes to surround your values if they may have strange characters or spaces

PW = 'password'
USER = 'username'
PORT = 8000

This is accessed via:

process.env.USER
process.env.PW
process.env.PORT

// For example:
const passwd = `${process.env.PW}`;

countmedown's People

Contributors

intelagense avatar gitcyco avatar nmpereira avatar carlabreis avatar

Watchers

 avatar  avatar  avatar

countmedown's Issues

Back-end MongoDB schema and setup.

Fields in db: data type

taskId: Number (key)
user: string
title: string
description: string
dueDate: date (utc time)
updatedDate: date (utc time, on any change - update this field)
completedDate: date (utc time, on checkbox update)
completed: boolean (checkbox)

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.