-
-
Notifications
You must be signed in to change notification settings - Fork 492
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New PSR2 + WP best practices ruleset #1067
Comments
I don't think that it should be added as an extra ruleset since PSR standards are not allowed in core (https://core.trac.wordpress.org/ticket/23357). For any non-standard development, users can just create their own custom rulesets, no? |
@dingo-d Just checking: you did read that I said an alternative ruleset for non-core WordPress-related development ? |
There are two ways to go ahead.
I think option 2 may be better. As the WordPress Community we should encourage that WordPress coding standards are used but still making it easy for people to use other coding styles. Though I do same my files different in plugins to match a more modern PHP naming convention then what WordPress has now. |
@jrfnl Yes I did read it, and I still don't see the merit for it, since users can create their own ruleset in any way they want :) Aside from helping people, who want to include some PSR coding standards with WordPress one, out, I don't know why would this need to be added as a separate ruleset. Better add it to a wiki page, showing users how to achieve that. That's just my opinion, didn't mean anything bad, just think that it's not that important :) |
I think in #740 I was favorable to a |
Closing for lack of consensus. |
A recent article by @tommcfarlin : https://tommcfarlin.com/using-psrs-in-wordpress-development/ got me thinking about PSR2 vs the WordPress Coding Standards.
I could easily create a ruleset which would allow devs to use PSR2 while still getting the benefits of the WP best practice sniffs and share it somewhere (separate repo/gist).
But what about potentially adding this as an extra ruleset here ? Not to replace any of the current rulesets, just as an alternative ruleset for non-core WordPress-related development.
Opinions ?
Related issues: #763 and #740
The text was updated successfully, but these errors were encountered: