Giter Club home page Giter Club logo

next11-plus's Introduction

Next.js template filled with best practices and examples.

Motivation

When you create an starter application with create-react-app, create-next-app or the majority of similiar command-line tools, the app your given is wonderful in many ways, but fails to follow best practices outside of the narrow scope of its base framework. create-react-app has many best practices for React, but not for CSS, accessibility, SEO, unit tests and a host of other concerns that any person wanting to publish a well-made website needs. Next.js, as an opinionated framework, addresses some of these problems, but still lacks examples of the various features that Next itself provides.

If those repos are trying to be the simplest form of a specific technology, this repo aims to be the simplest form of a family of technologies. This repo aims to be a slightly enhanced starter library,providing concise examples of all the features, best practices, and best-of-breed addons.

Why would you run Next without Sass? Instead of adding Sass to every project, let's add it to the starter project.

Collaboration

We're looking for a few good nit-pickers!

Make comments- request enhancements- find a type that can be better!

Is every pattern in this repository as good as it can possibly be?

Getting Started

Create a .env.local file and add these lines

NODE_ENV=development
SITE_URL=http://localhost:3000

Then, run the development server.

npm run dev
# or
yarn dev

Open http://localhost:3000 with your browser to see the result.

To lint both the JS and CSS, run

npm run lint

To do a production build, run

npm run build

Change Log

  • Started with a Next.js project bootstrapped with create-next-app.

  • Updated the config files

  • Installed Sass

  • Organized the CSS, made it mobile-first, added flexbox & will-change

  • Added WCAG and ARIA best practices

  • Added Next.js Document file, page-level Layouts, and error pages.

  • Added a next/image examples, local and remote.

  • Added Next-Sitemap

  • Addded Next.js recommended security headers

  • Added an example of major paradyms in React: Reducer, Hooks, Component, Controlled input, Context API

  • Atomized the React components

  • Added Metadata for SEO, and the favicon fields, and site.manifest

  • Upgraded ESLint to Typescript-ESLint with lots of custom ESLint rules for ease of use, and added opinionated type linting rules and overrides.

  • Added Stylelint for CSS Linting

  • Added an example API

  • Updated TSConfig and added lots of Typescript examples

  • Changed comments to use JSDoc format

  • Added some ES features: ??, Object.freeze, more

  • Updates the dependency versions of typescript, sass, next and eslint.

TODO

Contributors

  • Bishop Zareh, bishopz.com

Licence

MIT

next11-plus's People

Contributors

bishopz avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  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.