Coder Social home page Coder Social logo

finalproject's Introduction

finalproject's People

Contributors

jcloghesy avatar

Stargazers

 avatar

Watchers

 avatar Manpreet Singh avatar

finalproject's Issues

Tuesday's Tasks - Using Formik

John
display the data
render it as the data presents itself
Add data - this means make a form and make a post request to add data
Delete data
Update data
https://formik.org/
Formik
React hooks and components for hassle-free form validation. The world's leading companies use Formik to build forms and surveys in React and React
Native.

Image

Saturday's Meeting Tasks (Manpreet) - Front End Coding

Alvin's Notes (from Saturday's meeting) - Manpreet

1. AUTHO LOGIN

  • 1.0 Setup the Auth0 Login as per the quick start

2. CONNECT FRONT & BACK END (with Login)

- Overall process involves: making a use effect, to call your backend

 (i.e., localhost:8080/api/login)
 i. Front-end you send the user object to the back end
 ii. Back-end receives that object and checks the database for the "sub_id"
     a. matching sub_id -> return user that matches return to front-end
     b. no matching -> insert user to database, then return to front-end

- Specific Tasks

  • 2.1 Start a new branch (connect front & back-end with login)
  • 2.2 Create "profile.js" file and to place this connection into file
  • 2.2.1 In back-end make a route called app.get('/api/login')
  • 2.2.2 Front-end you send the user object to the back end
  • 2.2.3 Back-end receives object & checks the database for the "sub_id"
  a. matching sub_id -> return user that matches return to front-end
  b. no matching -> insert user to database, then return to front-end
  Use node-postgress query and to have function returns as promise)
  Ensure` function accepts sub=_id & returns a promise that resolves)

- Example Code

  user.sub_id === "google:oath-sj232ah18sh19sn3"
  SELECT * FROM USERS WHERE sub_id =  "google:oath-sj232ah18sh19sn3"
   this is going to return NO MATCH
   {
    id: 1
    email: aladf.com
    first_name: John
    last_name: nathan
    sub_id: = "google:oath-sj232ah18sh19sn3"
    }

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.