All Projects → jch254 → Starter Pack

jch254 / Starter Pack

Licence: mit
Combines React (ft. hooks), Redux, Redux-saga and TypeScript with Auth0 as a starting point for modern web apps with solid authentication

Programming Languages

typescript
32286 projects

Projects that are alternatives of or similar to Starter Pack

React Starter Kit
React, Redux, Webpack, Material UI, Boostrap 4, Code Splitting, HMR
Stars: ✭ 229 (+9.57%)
Mutual labels:  webpack, starter-kit, code-splitting
Reactql
Universal React+GraphQL starter kit: React 16, Apollo 2, MobX, Emotion, Webpack 4, GraphQL Code Generator, React Router 4, PostCSS, SSR
Stars: ✭ 1,833 (+777.03%)
Mutual labels:  webpack, starter-kit
React Redux Styled Hot Universal
react boilerplate used best practices and focus on performance
Stars: ✭ 147 (-29.67%)
Mutual labels:  webpack, starter-kit
Supertokens Core
Open source alternative to Auth0 / Firebase Auth / AWS Cognito
Stars: ✭ 2,907 (+1290.91%)
Mutual labels:  authentication, auth0
Webpack Require From
Webpack plugin that allows to configure path or URL for fetching dynamic imports
Stars: ✭ 142 (-32.06%)
Mutual labels:  webpack, code-splitting
Iceberg
Front-End Boilerplate built with React + Babel + Webpack + SASS
Stars: ✭ 144 (-31.1%)
Mutual labels:  webpack, starter-kit
React Redux Universal Boilerplate
An Universal ReactJS/Redux Boilerplate
Stars: ✭ 165 (-21.05%)
Mutual labels:  webpack, code-splitting
Reactjs Authentication Tutorial
Chuck Norris World App - A sample app that shows how to add authentication to a ReactJS app
Stars: ✭ 139 (-33.49%)
Mutual labels:  authentication, auth0
Polymer Skeleton
💀 Skeleton for Polymer 3 app with Webpack, PostCSS and Service Workers ready.
Stars: ✭ 185 (-11.48%)
Mutual labels:  webpack, starter-kit
Bedrock
Build a Node web app with user authentication, security, and more in under 10 minutes. Now supports React Hot Loading for super-fast development. 👌
Stars: ✭ 187 (-10.53%)
Mutual labels:  webpack, starter-kit
Feathers Vue
A boiler plate template using Feathers with Email Verification, Vue 2 with Server Side Rendering, stylus, scss, jade, babel, webpack, ES 6-8, login form, user authorization, and SEO
Stars: ✭ 195 (-6.7%)
Mutual labels:  webpack, authentication
Laravel Scaffold
The base for developing awesome projects
Stars: ✭ 142 (-32.06%)
Mutual labels:  starter-kit, authentication
Project Webcube
Continuously updated JS infrastructure for modern web dev
Stars: ✭ 141 (-32.54%)
Mutual labels:  webpack, starter-kit
Auth0.swift
Swift toolkit for Auth0 API
Stars: ✭ 146 (-30.14%)
Mutual labels:  authentication, auth0
Sharejs
💻js小技巧、react、webpack、redux、javascript及其它前端干货,持续更新ing
Stars: ✭ 141 (-32.54%)
Mutual labels:  webpack, redux-saga
React Boilerplate
A slightly opinionated yet dead simple boilerplate for React 17.x, Webpack 5 and React Router v5
Stars: ✭ 158 (-24.4%)
Mutual labels:  webpack, code-splitting
Koa Web Kit
🚀A Modern, Production-Ready, and Full-Stack Node Web Framework with React
Stars: ✭ 199 (-4.78%)
Mutual labels:  webpack, starter-kit
Code Splitting React Webpack
An example of how to code split with Webpack 2 and React Router
Stars: ✭ 138 (-33.97%)
Mutual labels:  webpack, code-splitting
Eleventy Starter Boilerplate
🚀 Eleventy Starter is production-ready with SEO-friendly for quickly starting a blog. ⚡ Built with Eleventy, ESLint, Prettier, Webpack, PostCSS, Tailwind CSS and Netlify CMS (optional).
Stars: ✭ 139 (-33.49%)
Mutual labels:  webpack, starter-kit
React Universal Saga
Universal React Starter Kit ft. Redux Saga
Stars: ✭ 184 (-11.96%)
Mutual labels:  webpack, redux-saga

Starter Pack

Build Status

Overview

Starter Pack combines React (ft. hooks), Redux and Redux-saga with Auth0's Universal Login as a starting point for modern web apps with solid authentication. Why reinvent the wheel? The app utilises Rebass to keep things looking decent. I built this as a way to quickly prototype new ideas.

Webpack (ft. various loaders/plugins/tools) is used to run a local development server and build the production version. Code splitting (with long-term caching in the production version) has been set up via Webpack and React. Webpack's SplitChunksPlugin is used to split vendor code. React.lazy is used for async component-centric code splitting and loading - see App.tsx as an example of creating a split point (restart the dev server if the new chunk is not emitted). MiniCssExtractPlugin is used to split CSS. HtmlWebpackPlugin is used to generate an index.html with the appropriate output assets injected, the Webpack manifest is inlined into index.html to save requests.

The app contains a 'locked down' Books page which requires a user to log in/sign up before content will be visible. The data is read from a local JSON file as this is a only demonstration/starting point. In the real world data would be fetched from an API - see apiService.ts. Protected routes in the API should check validity of the JWT token and return unauthorised if invalid. The app should then prompt the user to log in again. See Serverless API for a more detailed example of authentication in action.

This branch utilises TypeScript for type checking and transpliation to browser-friendly ES5 JavaScript while the master branch is a JavaScript implementation. ESLint (ft. plugins) is run on compilation and will fail the build if errors are reported. Eslint-plugin-css-modules provides type checking of CSS modules - identifying CSS files with unused classes and components using undefined CSS classes e.g. styles.doesNotExist.

Main

Modal

Recommended

Tools Used

AUTH0_CLIENT_ID and AUTH0_DOMAIN environment variable must be set before yarn run commands below.

E.g. AUTH0_CLIENT_ID=YOUR_CLIENT_ID AUTH0_DOMAIN=YOUR_DOMAIN yarn run dev

Running locally (with hot reloading)

  1. Sign up and create a new Auth0 app
  2. Add http://localhost:3001 as an Allowed Origin (CORS) for your newly created app (don't forget to press save)
  3. Run the following commands in the app's root directory then open http://localhost:3001
yarn install
yarn run dev

Building the production version

  1. Run the following commands in the app's root directory then check the /dist folder
yarn install
yarn run build

Running production version locally

  1. Run the following commands in the app's root directory then open http://localhost:3001
yarn install
yarn run prod

Running in Docker container

  1. Run the following commands in the app's root directory then submit requests to http://localhost:3001.
docker build -t starter-pack .
docker run -p 3001:3001 -e AUTH0_CLIENT_ID=YOUR_CLIENT_ID -e AUTH0_DOMAIN=YOUR_DOMAIN starter-pack SCRIPT_NAME

The SCRIPT_NAME value must be one of the npm script names in package.json - e.g. dev or prod. Omitting the SCRIPT_NAME variable will cause the container to exit with a 'No command specified' error and list the available commands.

Deployment/Infrastructure

Refer to the /infrastructure directory.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].