Difference between revisions of "JavaScript Working Group"

From Joomla! Documentation

(→‎Meetings: Added notes from JAB 12)
Line 37: Line 37:
 
==Meetings==
 
==Meetings==
  
* J! and Beyond 2012: TBA
+
===J! and Beyond 2012===
 +
 
 +
====Managing jQuery noConflict, potential solutions:====
 +
* add at the end of jQuery javascript file
 +
* load no_conflict.js
 +
* patch submitted by Beat: pre/post JavaScript
 +
 
 +
====Miscellaneous====
 +
* clean up library manager plugin
 +
* JSLint - add to the unit tests
 +
* JavaScript compression
 +
* Stop writing JavaScript in PHP!
 +
* Idea: module parameters for adding CSS and JavaScript (rather than adding it in the HTML body)
 +
* Ordering: Ability to add a declaration before or after
 +
 
 +
====Caching====
 +
* Browser Caching - ?#342384623749873 <--- cache bust
 +
* Joomla Caching - addScriptDeclaration: doesn't cache properly.
 +
* Different behavior in modules vs. components
 +
 
 +
====Where to load JavaScript?====
 +
* Add JavaScript at the END of the document.
 +
* OR: use defer for asynchronous loading.
 +
 
 +
====Possibility: add code on the client side to detect whether libraries are loaded.====
 +
* Would need to document
 +
* Or: Joomla.library('nameoflibrary', '1.0', 'libraryurl');
 +
* Just use Require.js (or don't, it's madness, has ordering issues because it's asynchronous)
 +
* Just use the plugin Joe authored. Or the patch Beat submitted.
 +
 
 +
====Stop====
 +
* writing inline JavaScript! (causes "flashes") (although Geraint disagrees (and so does Peter (and Danielle)))
 +
* Don't code onClick events directly into markup! Use stopPropagation.
 +
* Geraint brings up a good point: maybe you need to do something before DOMready... but it's on the level of eval()
 +
 
 +
====MooTools====
 +
* Optimize: We're currently loading everything.
 +
* As long as we're still using it, use it modularly, the way it was intended.
 +
* Might have to be done server side.
 +
* Look at LABjs.
 +
 
 +
====Follow up====
 +
* Start a GitHub branch
 +
* Start a Google Group - or do it on the CMS list.
 +
* Sort out 2.5 issues from 3.0 features
 +
* Look at replacing frontend MooTools
 +
* Get email addresses
  
 
[[Category:Documentation Working Group]]
 
[[Category:Documentation Working Group]]
 
[[Category:Working Groups]]
 
[[Category:Working Groups]]

Revision as of 10:51, 25 May 2012

The JavaScript Working Group is a Production Working Group. It is responsible for establishing standards for JavaScript and seeing that the JavaScript and/or JS frameworks are integrated and maintained.

Coordinators & PLT Contact[edit]

  • The coordinator for this working group is Joe LeBlanc.
  • The PLT Contact for this working group is Andy Tarr.

Announcements[edit]

External resources[edit]

Code Quality / Utilities[edit]

Libraries[edit]

Deliverables[edit]

Technical Work produced by this group[edit]

Communications[edit]

Roadmap[edit]

Meetings[edit]

J! and Beyond 2012[edit]

Managing jQuery noConflict, potential solutions:[edit]

  • add at the end of jQuery javascript file
  • load no_conflict.js
  • patch submitted by Beat: pre/post JavaScript

Miscellaneous[edit]

  • clean up library manager plugin
  • JSLint - add to the unit tests
  • JavaScript compression
  • Stop writing JavaScript in PHP!
  • Idea: module parameters for adding CSS and JavaScript (rather than adding it in the HTML body)
  • Ordering: Ability to add a declaration before or after

Caching[edit]

  • Browser Caching - ?#342384623749873 <--- cache bust
  • Joomla Caching - addScriptDeclaration: doesn't cache properly.
  • Different behavior in modules vs. components

Where to load JavaScript?[edit]

  • Add JavaScript at the END of the document.
  • OR: use defer for asynchronous loading.

Possibility: add code on the client side to detect whether libraries are loaded.[edit]

  • Would need to document
  • Or: Joomla.library('nameoflibrary', '1.0', 'libraryurl');
  • Just use Require.js (or don't, it's madness, has ordering issues because it's asynchronous)
  • Just use the plugin Joe authored. Or the patch Beat submitted.

Stop[edit]

  • writing inline JavaScript! (causes "flashes") (although Geraint disagrees (and so does Peter (and Danielle)))
  • Don't code onClick events directly into markup! Use stopPropagation.
  • Geraint brings up a good point: maybe you need to do something before DOMready... but it's on the level of eval()

MooTools[edit]

  • Optimize: We're currently loading everything.
  • As long as we're still using it, use it modularly, the way it was intended.
  • Might have to be done server side.
  • Look at LABjs.

Follow up[edit]

  • Start a GitHub branch
  • Start a Google Group - or do it on the CMS list.
  • Sort out 2.5 issues from 3.0 features
  • Look at replacing frontend MooTools
  • Get email addresses