degit https://github.com/casprine/backpack\#nextjs my-app
cd my-app
yarn start
Then open http://localhost:3000/ to see your app.
When you’re ready to deploy to production, create a minified bundle with yarn build
or npm run build
.
This project scaffold is created manaully with inspiration from creat-next-app. Project is clonend with degit. Make sure you have it installed globally.
degit https://github.com/casprine/backpack\#nextjs my-app
degit will create a directory called my-app inside the current folder. Inside that directory, it will generate the initial project structure.
.
├── LICENSE
├── README.md
├── next.config.js
├── package.json
├── pages
│ ├── _document.js
│ └── index.js
├── server.js
├── static
│ ├── fonts
│ │ └── ciruclar.ttf
│ └── sass
│ └── index.scss
├── todo.md
├── utils
│ ├── helpers.js
│ ├── index.js
│ └── localStorage.js
└── yarn.lock
Once the cloning is complete, enter the directory and install dependencies.
cd my-app
yarn
or
cd my-app
npm install
Once the installation is finished, you can run some commands in your project:
Runs the app in the development mode.
Open http://localhost:3000 to view it in the browser.
The page will reload if you make edits.
You will also see any errors in the console.
Builds the app for production to the .next
folder.
It correctly bundles React in production mode and optimizes the build for the best performance.
Starts the application in production mode.
The application should be compiled with npm run build
first.
Now you're ready to code & deploy your app!