@rivantmedia/next-template

2.0.0 • Public • Published

How to setup our Template

Right now our npx Template CLI have only one template i.e. NextJs Template.

Prerequisites:

  • NodeJS & NPM Installation

Downloading and Installation if a project folder had not been yet created

To install the NextJs Template for @rivantmedia, run the following command

$ npx @rivantmedia/next-template@latest

Give the desired Project Name as shown:

? Project name: project-name-of-your-choice

Them select any of the package installation manager (use arrow keys to navigate and enter to select):

? Which installation package manager would you like to choose?
> npm
  pnpm
  yarn

Type the following command to run the project:

for NPM

$ cd [project-name] && npm run dev

for PNPM

$ cd [project-name] && pnpm dev

for YARN

$ cd [project-name] && yarn dev

Downloading and Installation if a project folder had been created

To install the NextJs Template for @rivantmedia, run the following command

$ npx @rivantmedia/next-template@latest

Give the "." as Project Name as shown:

? Project name: .

Them select any of the package installation manager (use arrow keys to navigate and enter to select):

? Which installation package manager would you like to choose?
> npm
  pnpm
  yarn

Type the following command to run the project:

for NPM

$ npm run dev

for PNPM

$ pnpm dev

for YARN

$ yarn dev

How to add more Templates

  • Right now our npx Template CLI have only one template i.e. NextJs Template.
  • To add more templates, Create a template of your choice with everything you need.
  • Make sure that template does not have package-lock.json or yarn.lock or pnpm-lock.yaml.
  • Then, you need to add that template in the template folder.
  • After, this commit and publish the package.
  • You are now able to select the template of your choice to download and install.

How to select a template if multiple template are present:

$ npx @rivantmedia/next-template@latest

Now you can select any of the template (use arrow keys to navigate and enter to select):

? Which template would you like to choose?
> nextjs-ts-rivant-template
  nextjs-js-rivant-template
  react-js-rivant-template
  react-ts-rivant-template

Give the desired Project Name as shown:

? Project name: project-name-of-your-choice

Them select any of the package installation manager (use arrow keys to navigate and enter to select):

? Which installation package manager would you like to choose?
> npm
  pnpm
  yarn

Congratulations! you are ready to use this template

Readme

Keywords

none

Package Sidebar

Install

npm i @rivantmedia/next-template

Weekly Downloads

7

Version

2.0.0

License

MIT

Unpacked Size

18.2 kB

Total Files

17

Last publish

Collaborators

  • nightshift0607
  • paraswtf