Git Product home page Git Product logo

github_actions_test's Introduction

Boilerplate

This is a simple boilerplate designed to serve as robust template for quickly starting development on a Typescript based MERN web application.

Features

Required tools

These are necessary to build and run the project at full functionality

Recommended tools

To take full advantage of the linting/formatting, recommend adding the Prettier and ESLint VSCode extensions and configuring them as shown here for code highlighting and formatting on save. Skip to the section labeled "Add the following to your VS Code settings.json". To access your settings.json, follow what is linked here. See here for the differences between the two tools and how they work together.

Finally, we also recommend downloading the Live Share extension by Microsoft for improved Collaboration. This allows for easy peer programming on one shared repository instance.

Setup

MongoDB

The boilerplate uses MongoDB as the database to store information for authentication. To have this available for use, do the following

Recommend downloading MongoDB Compass for easy viewing and management of data.

SendGrid

The boilerplate uses SendGrid to send emails to users in order to verify their account, and also to reset their passwords. To have email functionality available for use, the PM/TL should do the following

Environment Variables

Create a file named .env in the root of the server folder and add the following variables with the appropriate values. PM/TLs should provide this to their developers.

ATLAS_URI=mongodb-connection-uri-from-above
COOKIE_SECRET=any-string
SENDGRID_API_KEY=sendgrid-api-key-from-above
SENDGRID_EMAIL_ADDRESS=sendgrid-sender-identity-email-from-above

Usage

NOTE: Currently, this project is best supported by running CLI commands from a bash/zsh environment. If using Windows, this can be achieved by following what's done here.

Installing dependencies

From the root folder, run the following to configure the project and its dependencies

$ yarn setup

If there is any need to reset the dependencies, simply run the following series of commands

$ yarn clean
$ yarn setup

Running the project

To run the project, use the following commands from the root folder

# run both server and client
$ yarn dev
# run server only
$ yarn server
# run client only
$ yarn client

Running tests

To run all the tests in the project, run the following from the root folder

$ yarn test

Running lintint/formatting

To check for linting issues from ESLint and fix what's possible, from the root folder run the following

$ yarn lint

To format the code appropriately with Prettier (don't need this if format on save was setup in VSCode), from the root folder run the following

$ yarn format

Common Problems

Fill in with problem scenario + solution as they arise

Incorrect Node Version

If you see an error message similar to this one:

The engine "node" is incompatible with this module. Expected version ">=12.0.0". Got "11.15.0"

This means you are using the wrong node version. This boilerplate relies on using node version 14.8. If you are using any other version of node, please use nvm to set node version to 14.8.3 as referenced here.

github_actions_test's People

Contributors

bew111 avatar zhouhelena avatar roshanbellary avatar

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.