Can I submit a plugin that follows the PSR-2 coding style guide?
This
if ($a === $b) {
}
$array = ['foo', 'bar'];
instead of
if ( $a === $b ) {
}
$array = [ 'foo', 'bar' ];
I would guess to the official plugin directory? Yes, the WP's own coding standards are recommended, but not required:
- Keep your code (mostly) human readable.
Intentionally obscuring code by hiding it with techniques or systems [...] Minified code may be used, however the unminified versions should be included whenever possible. We recommend following WordPress Core Coding Standards.
https://developer.wordpress.org/plugins/wordpress-org/detailed-plugin-guidelines/
PSR-2 is perfectly readable and there should be no issue with using it.