Coding Standard tools Help to develop yii standard application
Posted 01 March 2012 - 01:15 PM
But now I agree with jacmoe because it will ease contributions to the framework and avoid this: https://github.com/g...5d692a95b9f5373.
A layout definition file can even make things easier.
Check my extension
giix: a code generator for Yii.
The complete beginner's study guide for the Yii Framework
Posted 01 March 2012 - 01:26 PM
In same time if i get the same project but from Symfony2 and is writted on the same way, I can't say same and that just because Symfony2 have set writting rules and if the developper don't follow and if the code isn't readable, that mean the project manager is null and I put him in trash.
example of few rule:
- no braces for single line statements (braces exist in order to group multiple lines, no multiple lines no braces)
- space after conditions (they are not functions like f(x) )
- private menber start by _ and not static member start in minus
- indentation (space or tab, not problem but indent)
- presence of doc generated automaticly (@param and @return minimum)
and that all (and i think that the minimum)
Just for exemple Yii framework + somes plugins (all needed by all my website on yii) give 120.495 errors and 23.379 warnings with the rule code of Symfony2 and beleave me I prefert Yii to Symfony2, but that avanche of error in rules desesperate me, spececialy by the extensions folder giving to me arrond 80.000 errors in rule. So Symfony2 is not clean with they hown rules and give 5.005 errors and 1.007 warnings with the demos download.
Posted 01 March 2012 - 01:41 PM
Houps I forgot some directory for Symfony2 the good count is 36.473 errors and 7.980 warnings,
Posted 05 March 2012 - 07:38 AM
Despite me using different conventions than Yii does, I have no problem reading that code (although lack of braces on single-line if's and loops makes you read the code more carefully).