Tag archives for app

jQM{BR} App.utils.random()

Today I wrote a simple utility function to get random numbers or random array items as part ot jQM{BR} project.

Quick Example:

App.utils.random(10);
// return random between 0 and 10

App.utils.random(5,10);
// return random between 5 and 10

App.utils.random(['red','blue','green','yellow']);
// return a random item from given array

How to include:

You can add “utils” library in you app.js source file:

define([
    'jquery', 'jqmbr/AppClass',
    'jqmbr/app.utils'

], function(
    $, AppClass
) {
    ... app stuff ...
});

jqmbr/app.utils add utils namespace to the AppClass object.

NOTE: You can also usel AppClassFull in place of AppClass to load every available modules.

Source on GitHub:

You can see all App.utils methods on GitHub source!
Open GitHub!

Posted in BackboneJS, Tips & Tricks | Leave a comment

PowerApp :: utilities to introspect your application

PowerApp is a static class which methods give you the ability to introspect your application.

Continue reading »

Posted in CakePHP | Leave a comment

Swedish Greys - a WordPress theme from Nordic Themepark.