BakuJS
Formatter
Some small functions by adding on the prototype of the base objects.
The idea is for the formatter is to approach the formatting possibilities of fmt:message in JSTL.
Examples :
'Il y a {0, number, #,##0:fr} jour{0, choice,1<=|1>s}'._format(1200);
'Il y a {jours, number, #,##0:fr} jour{jours, choice,1<=|1>s}'._format({jours : 1});
'Rendez-vous le {date, date, dd/MM/yyyy}'._format({date : '2016-04-10'});
'Le resultat est {0, choice, 10<{1}|10>={2}}.'._format([12, 'petit', 'grand']);
DOM
Some shortcuts to avoid using a big library to do simple operations on the DOM with selectors.
Examples
baku.dom.list('h2 + div')
._css({'color' : 'red', 'text-decoration' : 'underline'})
._rmClass('ko');
Compilation
compress.sh full
compress.sh dom
compress.sh
Test
See the test page: http://test.ikilote.net/BakuJS/test.html
If you propose a correction or additional content, thank you to make all the tests are always ok, and/or add new.