cz-cli
eslint-plugin-react
cz-cli | eslint-plugin-react | |
---|---|---|
31 | 67 | |
16,409 | 8,818 | |
0.6% | 0.3% | |
2.3 | 8.4 | |
about 1 month ago | 15 days ago | |
JavaScript | JavaScript | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
cz-cli
-
Aider: AI pair programming in your terminal
Adopt a convention like commitizen: https://github.com/commitizen/cz-cli
'typeofchange(scopeofchange): reason for change'
It sort helps force devs to type out more meaningful commit messages.
-
What is a good message and size for a commit?
Commitizen Define a interface to write your commits and automatically and a prefix and a suffix to your message. (and others features not related)
-
Subject-First Commit Messages
Conventional commits are great, especially if you add in commit linting.
Being able to programmatically increment semantic versions and automatically generate relevant changelogs is awesome.
It’s also nice to implement Commitizen[0] for a little hand holding until folks get used to the linting.
I used to care a lot about doing things the way that felt right to me, but now I just want some common standard that is easy for everyone to follow, easy to automate, and easy to verify programmatically.
Things like conventional commits and semantic versioning aren’t perfect, but they are quite good and apply broadly to many use cases with common tooling and conventions.
--
[0]: http://commitizen.github.io/cz-cli/
-
Automating code patterns with Husky
In the world of software development, maintaining consistent code quality and ensuring that the codebase adheres to predefined patterns and guidelines is crucial. However, manually enforcing these standards can be time-consuming and error-prone. This is where automation tools like Husky, Lint-Staged, Commitlint, and Commitizen come to the rescue. In this post, we will explore how these tools can be combined to streamline your development workflow.
-
How to set up Commitzen with Husky
Conventional commits specification contains a set of rules for creating an explicit commit history, which makes it easier to write automated tools on top of, for example, semantic release. You can manually follow this convention in your project or use a tool to assist you, such as Commitizen.
-
Automated release with Semantic Release and commitizen
When working with JavaScript projects, managing version numbers and commit messages is important for the maintainability of the project. Since 2020 I have been the main developer of Atomic Calendar Revive a highly customisable Home Assistant calendar card, I found maintaining versions and releases to be cumbersome until recently. In this article, I will introduce the commitizen and semantic-release packages for creation or appropriate commit messages and semantic versioning. I will also provide examples of how I am currently using these packages to streamline my release workflow and project maintenance.
-
Does it make sense to write commit messages that include notes to yourself on how the project is going?
I use Commitizen to enforce a strict commit message. It's not required - but it makes my life easier. It adheres to a standard - but it's certainly not "the" standard.
-
What is the relation between commitizen-tools/commitizen and commitizen/cz-cli?
When I googled, I found cz-cli project first: https://github.com/commitizen/cz-cli
-
Ideas for minimum PHP pipeline for a small team
Same thing with git commits. Something like commitizen. It forces a specific format of your commits. And if you're using an associated issue/bug tracker that can automatically link to commits you can set up to format like that.
-
How do I learn modern web development?
That may also serve as a good entry point for nodeJS via the tools: commitizen, commitLint. That is you implement them within your project, and then also think about how to implement via CI/CD remotely.
eslint-plugin-react
-
Interesting Bugs Caught by ESLint's no-constant-binary-expression
> [1] https://github.com/jsx-eslint/eslint-plugin-react/blob/maste...
From what I remember, being able to pass children as a prop is considered a side-effect of an implementation detail, that breaks the expected abstraction. There really isn't any reason to use it, and I think there's a chance it may even confuse the virtual dom diffing?
Also this would prevent you from accidentally doing both at once:
Is it me?}>
-
Speeding up the JavaScript ecosystem – Polyfills gone rogue
I try to focus on the issues rather than individuals, but the root of the problems in the listed eslint plugin libraries points to ljharb.
If you do some simple digging into these libraries, you will find that these types of commits are quite common within them.
https://github.com/jsx-eslint/eslint-plugin-react/commit/e1d...
https://github.com/jsx-eslint/jsx-ast-utils/commit/bad51d062...
https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/commit/...
He would rather see the download count of these polyfill libraries https://github.com/ljharb/ljharb#projects-i-maintain increase, compared to assessing the health of the JavaScript ecosystem.
-
The Best ESLint Rules for React Projects
An obvious pick for React projects, but eslint-plugin-react along with their plugin:react/recommended rule set is a must. This will give you some sensible rules such as requiring a key to be specified in JSX arrays. eslint-config-airbnb is another good (if a bit loose) base rule set on top of eslint-plugin-react to start from.
-
Avoid "&&" Operator for Conditional Rendering in React
If you already have the eslint-plugin-react installed, you can enable the following rule.
-
Create React UI Lib 1.1: Ladle and ESLint
You can also add ESLint now (props to @femincan for the suggestion). It comes with recommended settings for these plugins: typescript, prettier, react, react-hooks, jsx-a11y.
- Confusion over one of the examples of the jsx-no-literals linting rule
-
What's weirdest webdev practice in your company?
Also for what it’s worth, there’s a React ESLint code rule that can enforce this behavior either way for Component props - I’m not in front of a code base atm, but I wonder if my preference for the syntax above is influenced by a popular linting preset like AirBnB which enforces this rule? https://github.com/jsx-eslint/eslint-plugin-react/blob/master/docs/rules/jsx-curly-brace-presence.md
-
Removing Default React Imports. For a Cleaner Code
The missing piece is on this page, in a small note at the end of the page: the eslint rule to disallow missing React when using JSX.
-
Ask HN: What are you predictions for 2023?
Thanks for weighing in, that's good to know. After wondering if this could be auto-refactored, I came across https://github.com/jsx-eslint/eslint-plugin-react/blob/maste..., will definitely have to give that (with `--fix`) a try in the new year and see if I can get the team on board! – desire for typescript being a compelling factor.
Personally I do like the non-destructured `props.abc` throughout component code, really helps clarify at a glance where something is coming from, whether it's locally or externally defined, etc. Code style is an endless exercise in compromises/opinions though, even _with_ tools like eslint and prettier.
-
Recommended React Hooks Convention
eslint-plugin-react react/hook-use-state
What are some alternatives?
semantic-release - :package::rocket: Fully automated version management and package publishing
stylelint-config-prettier - Turns off all rules that are unnecessary or might conflict with prettier.
tig - Text-mode interface for git
berry - 📦🐈 Active development trunk for Yarn ⚒
commitizen - Create committing rules for projects :rocket: auto bump versions :arrow_up: and auto changelog generation :open_file_folder:
prop-types - Runtime type checking for React props and similar objects
tortoisegit - Windows Explorer Extension to Operate Git; Mirror of official repository https://tortoisegit.org/sourcecode
javascript - JavaScript Style Guide
release-please - generate release PRs based on the conventionalcommits.org spec
razzle - ✨ Create server-rendered universal JavaScript applications with no configuration
standard-version - :trophy: Automate versioning and CHANGELOG generation, with semver.org and conventionalcommits.org
eslint-plugin-prettier - ESLint plugin for Prettier formatting