Skip to content
/ template-node Public template

Node.js project scaffolding tool designed to speed up the initial setup of Node.js applications. This repository provides a solid foundation for building scalable and maintainable Node.js projects, with built-in best practices and commonly used configurations.

License

Notifications You must be signed in to change notification settings

jdevelop-io/template-node

Repository files navigation

Template Node

Build Test Code Quality License: MIT WakaTime

Template Node is a Node.js project scaffolding tool designed to speed up the initial setup of Node.js applications. This repository provides a solid foundation for building scalable and maintainable Node.js projects, with built-in best practices and commonly used configurations.

Features

  • TypeScript: Use TypeScript for a better development experience and improved code quality.
  • ESLint: Lint your code with ESLint to maintain consistent coding standards.
  • Prettier: Format your code with Prettier to keep it clean and consistent.
  • Jest: Test your code with Jest to ensure its correctness and reliability.
  • Husky: Use Husky to run tasks on Git hooks and enforce code quality.
  • Lint-Staged: Run ESLint and Prettier on staged files to catch errors before committing.
  • GitHub Actions: Use GitHub Actions for continuous integration and automated testing.

Getting Started

Prerequisites

Make sure you have Node.js and pNPM installed on your machine before running the project.

Installation

  1. Clone the repository:

    git clone --depth 1 https://github.com/jdevelop-io/template-node.git
    cd template-node
  2. Remove the .git directory to start with a clean git history:

    rm -rf .git
  3. Initialize a new git repository:

    git init
  4. Install the dependencies:

    pnpm install

Scripts

  • pnpm build : Build the project.
  • pnpm buid:watch : Build the project in watch mode.
  • pnpm test : Run the tests.
  • pnpm test:watch : Run the tests in watch mode.
  • pnpm test:coverage : Run the tests with coverage.
  • pnpm test:coverage:watch: Run the tests with coverage in watch mode.
  • pnpm format : Format the code and fix formatting errors.
  • pnpm format:check : Check the code for formatting errors.
  • pnpm lint : Lint the code and fix linting errors.
  • pnpm lint:check : Check the code for linting errors.

Project Structure

template-node
├── .github
│   ├── workflows
│   │   ├── build.yml
│   │   ├── code_quality.yml
│   │   └── tests.yml
├── .husky
│   └── pre-commit
├── coverage
├── dist
├── node_modules
├── src
├── test
│   └── unit
├── .editorconfig
├── .gitignore
├── .prettierignore
├── eslint.config.mjs
├── jest.config.ts
├── LICENSE
├── lint-staged.config.mjs
├── package.json
├── pnpm-lock.yaml
├── prettier.config.mjs
├── README.md
└── tsconfig.json

Contributing

Contributions are welcome! If you have any ideas, suggestions, or issues, feel free to open an issue or submit a pull request.

License

This project is licensed under the MIT License. See the LICENSE file for details.

About

Node.js project scaffolding tool designed to speed up the initial setup of Node.js applications. This repository provides a solid foundation for building scalable and maintainable Node.js projects, with built-in best practices and commonly used configurations.

Topics

Resources

License

Stars

Watchers

Forks