Giter Club home page Giter Club logo

nextjs-boilerplate's Introduction

VivifyIdeas NextJS boilerplate

If you are using our NextJS boilerplate we recommend you use it with our laravel boilerplate.

Start

Locally

yarn run dev

Docker

Build and run your container locally

docker-compose up --build

Built in functions

  • HTTPS mode in dev
  • Redux & Saga
  • Formik & Yup
  • Immerjs
  • Sign in
  • Sign up
  • Facebook sign in
  • Google sign in
  • Forgot & reset password
  • Internationalization
  • Edit profile

TBD

  • Change password

Code structure and technologies

For our forms we use Formik, and for validation we use Yup.

In components folder there are some examples of our forms, they all use custom text inputs which are located in components/shared/formFields, and in validation folder you will find some Yup validation examples.

├── components
├──── auth
├──── shared
├─────── formFields
├────────── PasswordInputWithLabel.js
├────────── TextInputWithLabel.js
└── validation

State Management

For state management we use React Redux with Redux Saga and Reselect.

├── store
├──── actions
├──── index.js
├──── reducer
├──── selectors
└──── sagas

Localization

For more details check out next-i18next.

Route Guards

There are HOC made for this (withAuth, withGuest). You can find examples in utils/hoc.

Logged in user is beeing server side rendered you can find the code in pages/_app.js in getInitialProps method.

HTTPS Mode

To run this application in HTTPS mode you will need to generate certificates localy and put them in certs folder in root of your project. The required certificate files are server.key and server.ctr. After that you can run yarn dev-https command to run it in HTTPS.

nextjs-boilerplate's People

Contributors

alexsensei avatar mrgagi avatar nikolasp avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

nextjslib

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.