Skip to content

Cognitive Test App written with React, AWS, MongoDB and TailwindCSS. Contains nine custom brain games with results analysis, database connectivity and a user profile/login system. Desktop demo link below.

Notifications You must be signed in to change notification settings

jgddesigns/cognitive_test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 

Repository files navigation

COGNITIVE GAMES APP




INTRODUCTION:

The purpose of this app is for users to take a set of 10-15 different cognitive tests. Initially the baseline is determined by taking a test under regular circumstances.

Afterward, variables are introduced such as use of herbal supplements or walks in nature. Previously attempted tests are to be taken again following the introduction of a specific variable.

A comparison is made with subsequent analysis, based on typically expected results and how the variables affect or have no influence on a particular test.


========================================


INCLUDES:

Welcoming Page
Test Info
Signup/Login
User Profile (Settings, Individual results and analysis)
Results and Analysis


BUILT WITH:

React (Next framework)
Typescript
Tailwind
AWS Dynamo DB -- Needs AWS Keys.
AWS Cognito -- Needs AWS Keys.
Node.js & npm
Node Version Manager (nvm)


========================================


GETTING STARTED (for Windows -- Mac and Linux instructions to be determined):

Install git ( https://git-scm.com/book/en/v2/Getting-Started-Installing-Git)
Install Node (https://nodejs.org/en/learn/getting-started/how-to-install-nodejs)

1. Use terminal within IDE to navigate to desired folder for project. Use git to clone the project (git clone https://github.com/jgddesigns/cognitive_test)
2. In cognitive_test directory, run 'npm install' in terminal command line (if scripts are disabled, open Windows Powershell as administrator and enter 'Set-ExecutionPolicy Unrestricted' in the command line)
3. Next run 'npm run build' in terminal command line
4. Launch server 'npm run dev' in terminal command line (default local url in broswer is localhost:3000)


If there are any issues, it could be due to an incompatible React or Node version. If you have Node already installed and it's different than the dependency for this app, nvm can be used to switch between Node versions.

Node Version Manager (nvm) Setup Instructions:

https://www.freecodecamp.org/news/node-version-manager-nvm-install-guide/

(or lookup on ChatGpt, Google, etc...)


========================================


CODING DOCUMENTATION FORMAT


Naming Conventions:

- snake_case for functions and variables
- PascalCase for Components
- PascalCase, camelCase for React state variables
- UPPER_SNAKECASE for credentials

Example:
function create_list(){
    console.log("here is a function")
}

const variable_name = "name"

export default function ComponentName (props: any) { 
    //component content
    return (
        <div>
        </div>
    )
}

const [StateVariable, setStateVariable] = React.useState(false)

const CREDENTIAL_NAME = "asdf123"

Use the following convention for documenting each function in the code comments:
//Description of function's purpose
//@param param1: Param #1 for the function and it's use (if needed, otherwise 'None')
//@param param2: Param #2 for the function and it's use (if needed)
//@return: Description of what is returned in the function (if no return, 'Void')

Example:
//Based on the column header clicked, sort the results by that column.
//@param type: The string of the column name that was clicked.
//@return: Void.
const SortHandler = (type) => {
    
    if(type == "Name"){
        setToggleName(!ToggleName)
    }
    
    if(type == "EFIS"){
        setToggleEFIS(!ToggleEFIS)
    }
    
    if(type == "Role"){
        setToggleRole(!ToggleRole)
    }
    
    if(type == "District"){
        setToggleDistrict(!ToggleDistrict)
    }

    setSortBy(type)
    renderResults(resultsMap)
}



================================================


MAIN PAGE LOCATION: cognitive_test/src/app/page.tsx

GAMES COMPONENETS LOCATION: cognitive_test/src/tests

DATABASE COMPONENT LOCATION: cognitive_test/src/database

About

Cognitive Test App written with React, AWS, MongoDB and TailwindCSS. Contains nine custom brain games with results analysis, database connectivity and a user profile/login system. Desktop demo link below.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages