Material Kit PRO React features over 1000 individual components, giving you the freedom of choosing and combining. The product comes with a simple JWT authentication flow: login/register/logout powered by a Node JS API Server (PRO version).
Features
- Premium Material UI design - Designed by Creative-Tim
- React, Redux, Redux-persist
- Authentication: JWT Login/Register/Logout
- Backend Server- Node JS API Server PRO
- SQLite / TypeORM / Joy / Docker
- MongoDB / Mongoose / Joy Docker (separate branch, same project)
To use the product Node JS (>= 12.x) is required and GIT to clone/download the project from the public repository.
Step #1 - Clone the project (private repository)
$ git clone https://github.com/app-generator/priv-react-material-kit-pro.git
$ cd priv-react-material-kit-proStep #2 - Install dependencies via NPM or yarn
$ npm i
// OR
$ yarnStep #3 - Start in development mode
$ npm run start
// OR
$ yarn startThe backend API server address is saved in
src/config/constant.js.
export const API_SERVER = "http://localhost:5000/api/";Frontend api has been created at
src/api/auth.js.
const axios = Axios.create({
baseURL: `${baseURL}/api`,
headers: { "Content-Type": "application/json" },
});Register implementation:
- Frontend method with call to backend
- Form validation
- Error handling
Login implementation:
- Frontend method with call to backend
- Form validation
- Error handling
Logout implementation:
- Frontend method with call to backend
User Context:
- The user account is now saved both to the React.Context wrapper and localStorage
Protected routes:
- The user cannot access protected routes like /admin, /rtl without being logged in.
- Example of 3 different routes:
<ProtectedRoute path="/admin" component={AdminLayout} />
<ProtectedRoute path="/rtl" component={RtlLayout} />
<Route path="/auth" component={AuthLayout} />API Descriptor
The product uses implements a Unified API definition exposed by all API servers crafted by AppSeed. For more information, please access the official documentation:
- All API Servers - the full index
- Unified API Definition - methods implemented accross all servers
Express / Nodejs Starter with JWT authentication, and SQLite or MongoDB persistance. Authentication Flow uses json web tokens via Passport library - passport-jwt.
Features
- Simple, intuitive codebase - can be extended with ease.
- Typescript
- Data validation with Joy
- Branches:
- Master: NodeJS / Express / SQLite / TypeORM
- Mongo: NodeJS / Express / MongoDB / Mongoose
- Auth: Passport /
passport-jwtstrategy
Step #1 - Clone the project (private repository)
$ git clone https://github.com/app-generator/priv-api-server-nodejs.git
$ cd priv-api-server-nodejsStep #2 - Install dependencies via NPM or yarn
$ npm i
// OR
$ yarnStep #3 - Run the SQLite migration via TypeORM
$ yarn typeorm migration:run
Step #4 - Start the API server (development mode)
$ npm dev
// OR
$ yarn devStep #5 - Production Build (files generated in build directory)
$ npm build
// OR
$ yarn buildStep #6 - Start the API server for production (files served from build/index.js)
$ npm start
// OR
$ yarn startThe API server will start using the PORT specified in .env file (default 5000).
React Node Material Kit PRO - Provided by Creative-Tim and AppSeed App Generator.
