opensource-nepal / node-nepali-datetime

A Node project designed to support native JavaScript-like features for Nepali date and times. It includes features such as 'NepaliDate' for Nepali date support and 'dateConverter' for date conversions.
GNU General Public License v3.0
63 stars 18 forks source link

Add prettier check on CI #58

Closed aj3sh closed 6 months ago

aj3sh commented 1 year ago

Problem: Currently, we have a Prettier check implemented solely as a pre-commit hook. While this is a valuable step in maintaining code quality, it's not sufficient as it can be bypassed. Developers can inadvertently or deliberately skip this step, potentially leading to inconsistent code formatting.

Proposal: We should enhance our code formatting enforcement by adding a Prettier check to our GitHub Actions workflow. This will ensure that code formatting is consistently applied before changes are merged into our codebase.

binodnepali commented 1 year ago

Problem: Currently, we have a Prettier check implemented solely as a pre-commit hook. While this is a valuable step in maintaining code quality, it's not sufficient as it can be bypassed. Developers can inadvertently or deliberately skip this step, potentially leading to inconsistent code formatting.

Proposal: We should enhance our code formatting enforcement by adding a Prettier check to our GitHub Actions workflow. This will ensure that code formatting is consistently applied before changes are merged into our codebase.

Actually, we don't need really prettier check on CI. we can run the lint fix script before executing the build.

aj3sh commented 1 year ago

Actually, we don't need really prettier check on CI. we can run the lint fix script before executing the build.

This creates a change in the source code, which requires a new commit and push in a branch. Am I correct?

binodnepali commented 1 year ago

Actually, we don't need really prettier check on CI. we can run the lint fix script before executing the build.

This creates a change in the source code, which requires a new commit and push in a branch. Am I correct?

Yeah, my bad. You are correct. We should run only check (adding one step in workflow).