30秒学会 JavaScript 片段 – pluralize
Returns the singular or plural form of the word based on the input number. If the first argument is ...
Returns the singular or plural form of the word based on the input number. If the first argument is ...
Returns the average of an array, after mapping each element to a value using the provided function. ...
Resets all styles to default values with one property. This will not affect direction and unicode-bi...
Decapitalizes the first letter of a string. Decapitalize the first letter of the string and then add...
Returns a sorted array of objects ordered by properties and orders. Uses Array.prototype.sort(), Arr...
Randomizes the order of the values of an list, returning a new list. Uses the Fisher-Yates algorithm...
Pads a given number to the specified length. Use Int32.ToString() with an appropriate format specifi...
Creates a counter with the specified range, step and duration for the specified selector. Check if s...
Returns the last element in an array. Check if arr is truthy and has a length property, use arr.leng...
Returns the type of the given object. Use typeof() on the given object’s type.