1.0.6 • Published 5 years ago

cms7-jquery v1.0.6

Weekly downloads
-
License
ISC
Repository
-
Last release
5 years ago

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

jQuery classes polyfill for IE

will be automatically injected on import

IE10 viewport hack for Surface/desktop Windows 8 bug

will be automatically injected on import

fix for safari bug on readonly input

will be automatically injected on import

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago