Applied Prettier Formatting and Configured .prettierrc.json and .prettierignore#237
Open
sakina1303 wants to merge 1 commit intoAOSSIE-Org:mainfrom
Open
Applied Prettier Formatting and Configured .prettierrc.json and .prettierignore#237sakina1303 wants to merge 1 commit intoAOSSIE-Org:mainfrom
sakina1303 wants to merge 1 commit intoAOSSIE-Org:mainfrom
Conversation
…n & .prettierignore
Contributor
Author
|
Hi Sir @Aditya062003 , |
Contributor
|
Hey @sakina1303, I noticed that this feature is already implemented in my PR #118. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
-To maintain a uniform code style and enhance code quality across the project, Prettier formatting scripts have been added to package.json. These scripts enable developers to easily format code and check for adherence to predefined formatting rules. Additionally, a .prettierrc file has been created to define project-specific Prettier configuration rules, ensuring consistency and reducing the need for manual adjustments.
Changes Made
Added the necessary scripts in package.json:
Scripts were added to package.json to enable automatic code formatting and validation. One script formats all project files, while the other checks for adherence to Prettier rules without making changes.
Created a .prettierrc.json and prettierignore file to define custom Prettier configuration settings.
How It Works
npm run format → Automatically formats all files in the project according to Prettier rules.
npm run format:check → Checks if files follow Prettier formatting without making any changes.
.prettierrc.json → Stores the project's Prettier configuration to maintain consistent formatting across the codebase.
.prettierignore → Specifies files and directories that should be ignored by Prettier, preventing unnecessary formatting of certain files like build outputs, dependencies, or specific project files.
Benefits
Fixes #235