cms7-jquery
v1.0.6
Published
- ### __log__: which is a shortcut for console.log - ### __$__ and __jQuery__: the jquery's famous $ and jQuery variable - ### __stackTrace function() -> Error__: returns an error object containing current stack trace - ### __logStackTrace function() -
Downloads
4
Readme
jQuery & javascript extensions
Adds following to window variable:
log: which is a shortcut for console.log
$ and jQuery: the jquery's famous $ and jQuery variable
stackTrace function() -> Error: returns an error object containing current stack trace
logStackTrace function() -> void: prints current stack trace in console
Adds the following methods to any jQuery variable:
hasAttr function (name) -> Boolean: checks if a jquery object has the given attribute.
$('.test').hasAttr('id')
equals function(jQueryObject) -> Boolean: checks if a jquery object equals the given jquery object.
$('.test').equals($('.test'))
outerHTML function() -> String: returns the jquery object's outer html.
$('.test').outerHTML()
Adds the following methods to javascript Number:
padZero function(size) -> String: inserts 0s before a number until the length is equal to size parameter
var x = 123; x.padZero(5) prints: 00123
format function(separator = ',') -> String: thousand separator for mostly currencies
var x = 123000; x.format('/') prints: 123/000
Adds the following methods to javascript String:
format function(templateString, ...args): just like c# String.format
String.format('Hi, {0}', 'Akbar') prints: Hi, Akbar
Adds the following to FormData:
print function() -> String: prints FormData object
put function(object) -> FormData: puts all properties of object recursively into FormData