I agree with Josh. Also, I would prefer NOT using IDs for styling. It forces 
the use of CSS in the JSP, which defeats the purpose of pulling it OUT of the 
JSP.

Pulling JS out of the JSPs will take a lot more work, though. We would need to 
move forward with some better JS architecture to fit the extendibility of 
uPortal.

I’m all for it, though.

Cheers,
Jodie.

> On Nov 6, 2014, at 8:37 AM, Josh Helmer <[email protected]> wrote:
> 
> I mostly good with that, although I really don't like the recommendation of 2 
> space indent w/ 4 space continuing indent.    I personally *really* prefer 4 
> space indent and find 2 space indent difficult to read.   Other than that, I 
> don't see anything too objectionable in the google recommendations.
> 
> On the JS side, again, I'm in favor of some sort of recommended standard,.  
> Something I would think is probably even more important would be a push to 
> move as much of the JS out of the JSPs as possible and then try to use 
> js[hl]int on the code as part of our maven build.  That will catch some of 
> the 
> stylistic things but will also enforce best practices on the JS code (eg. 
> must 
> use var, must use semicolons, etc) which is probably even more valuable.
> 
> It would be nice to try and move the CSS out of the JSP too.  Then we could 
> use some tooling to enforce best practices and move more of the styling to 
> less.   CSS is just a lot tricker to move though because of the namespacing 
> issues unless we want to discourage the use of IDs in CSS rules (which might 
> not be so bad?)
> 
> My $0.02.
> Josh
> 
> 
> On Thursday, November 06, 2014 09:04:58 AM Andrew Petro wrote:
>> uPortal developers,
>> 
>> I think it would be wise for uPortal to adopt tighter code style
>> conventions (and to enforce these in the release process via build
>> automation, since without automation style conventions will not be adhered
>> to.)
>> 
>> I think those code conventions should be Google's.
>> 
>> https://google-styleguide.googlecode.com/svn/trunk/javaguide.html
>> 
>> https://google-styleguide.googlecode.com/svn/trunk/javascriptguide.xml
>> 
>> etc.
>> 
>> The product has a heap of code of varying style.  I'd see a changeset to
>> pervasively adjust style to the convention as only appropriate for a MAJOR
>> release.  As in, uPortal 5.
>> 
>> So.  This is the initial conversation-starting email expressing intention
>> to advocate for this improvement for uPortal 5.
>> 
>> Andrew
> 
> 
> -- 
> You are currently subscribed to [email protected] as: 
> [email protected]
> To unsubscribe, change settings or access archives, see 
> http://www.ja-sig.org/wiki/display/JSG/uportal-dev


-- 
You are currently subscribed to [email protected] as: 
[email protected]
To unsubscribe, change settings or access archives, see 
http://www.ja-sig.org/wiki/display/JSG/uportal-dev

Reply via email to