Merge pull request #1914 from 30-seconds/retitle-snippets
Retitle snippets
This commit is contained in:
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: functionName
|
||||
title: Function name
|
||||
tags: array,intermediate
|
||||
firstSeen: 2021-06-13T05:00:00-04:00
|
||||
---
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: CSVToArray
|
||||
title: CSV to array
|
||||
tags: string,array,intermediate
|
||||
firstSeen: 2018-06-27T20:57:54+03:00
|
||||
lastUpdated: 2022-01-30T12:14:39+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: CSVToJSON
|
||||
title: CSV to JSON
|
||||
tags: string,object,advanced
|
||||
firstSeen: 2018-06-27T21:14:24+03:00
|
||||
lastUpdated: 2022-01-30T12:14:39+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: HSBToRGB
|
||||
title: HSB to RGB
|
||||
tags: math,intermediate
|
||||
firstSeen: 2020-09-18T14:25:07+03:00
|
||||
lastUpdated: 2020-09-18T14:25:07+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: HSLToRGB
|
||||
title: HSL to RGB
|
||||
tags: math,intermediate
|
||||
firstSeen: 2020-10-01T23:15:49+03:00
|
||||
lastUpdated: 2020-10-04T11:24:27+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: JSONToFile
|
||||
title: JSON to file
|
||||
tags: node,intermediate
|
||||
firstSeen: 2017-12-17T17:55:51+02:00
|
||||
lastUpdated: 2020-10-20T23:02:01+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: JSONtoCSV
|
||||
title: JSON to CSV
|
||||
tags: array,string,object,advanced
|
||||
firstSeen: 2018-07-06T20:25:46+03:00
|
||||
lastUpdated: 2021-10-13T19:29:39+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: RGBToHSB
|
||||
title: RGB to HSB
|
||||
tags: math,intermediate
|
||||
firstSeen: 2020-09-18T14:25:07+03:00
|
||||
lastUpdated: 2020-10-22T20:24:30+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: RGBToHSL
|
||||
title: RGB to HSL
|
||||
tags: math,intermediate
|
||||
firstSeen: 2020-10-01T23:16:30+03:00
|
||||
lastUpdated: 2020-10-04T11:25:12+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: RGBToHex
|
||||
title: RGB to hex
|
||||
tags: string,math,intermediate
|
||||
firstSeen: 2017-12-17T17:55:51+02:00
|
||||
lastUpdated: 2020-11-03T22:11:18+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: URLJoin
|
||||
title: Join URL segments
|
||||
tags: string,regexp,advanced
|
||||
firstSeen: 2018-01-16T15:53:03+02:00
|
||||
lastUpdated: 2020-10-22T20:24:44+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: UUIDGeneratorBrowser
|
||||
title: Generate UUID (browser)
|
||||
tags: browser,random,intermediate
|
||||
firstSeen: 2017-12-29T09:47:10+02:00
|
||||
lastUpdated: 2020-10-22T20:24:44+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: UUIDGeneratorNode
|
||||
title: Generate UUID (Node.js)
|
||||
tags: node,random,intermediate
|
||||
firstSeen: 2017-12-29T09:47:10+02:00
|
||||
lastUpdated: 2020-10-22T20:24:44+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: accumulate
|
||||
title: Partial sum array
|
||||
tags: math,array,intermediate
|
||||
firstSeen: 2020-05-04T12:20:46+03:00
|
||||
lastUpdated: 2022-01-30T13:10:13+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: addClass
|
||||
title: Add class to HTML element
|
||||
tags: browser,beginner
|
||||
firstSeen: 2020-12-30T19:21:15+02:00
|
||||
lastUpdated: 2020-12-30T19:21:15+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: addDaysToDate
|
||||
title: Add days to date
|
||||
tags: date,intermediate
|
||||
firstSeen: 2020-10-12T03:03:18+03:00
|
||||
lastUpdated: 2020-11-28T19:18:29+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: addEventListenerAll
|
||||
title: Add event listener to all targets
|
||||
tags: browser,event,intermediate
|
||||
firstSeen: 2021-04-22T08:53:29+03:00
|
||||
lastUpdated: 2021-04-22T08:53:29+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: addMinutesToDate
|
||||
title: Add minutes to date
|
||||
tags: date,intermediate
|
||||
firstSeen: 2020-11-28T19:27:46+02:00
|
||||
lastUpdated: 2020-11-28T19:27:46+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: addMultipleListeners
|
||||
title: Add multiple listeners
|
||||
tags: browser,event,intermediate
|
||||
firstSeen: 2020-10-08T00:40:30+03:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
---
|
||||
title: addStyles
|
||||
title: Add styles to HTML element
|
||||
tags: browser,beginner
|
||||
firstSeen: 2021-01-07T00:37:43+02:00
|
||||
lastUpdated: 2021-01-07T00:37:43+02:00
|
||||
---
|
||||
|
||||
Adds the provided styles to the given element.
|
||||
Adds the provided styles to the given HTML element.
|
||||
|
||||
- Use `Object.assign()` and `ElementCSSInlineStyle.style` to merge the provided `styles` object into the style of the given element.
|
||||
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: addWeekDays
|
||||
title: Add weekdays to date
|
||||
tags: date,intermediate
|
||||
firstSeen: 2020-10-11T16:51:39+03:00
|
||||
lastUpdated: 2021-01-08T00:23:44+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: all
|
||||
title: Test if all array elements are truthy
|
||||
tags: array,beginner
|
||||
firstSeen: 2018-02-14T11:46:15+02:00
|
||||
lastUpdated: 2020-10-18T20:24:28+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: allEqual
|
||||
title: Check if array elements are equal
|
||||
tags: array,beginner
|
||||
firstSeen: 2018-08-03T00:03:08+03:00
|
||||
lastUpdated: 2020-10-18T20:24:28+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: allEqualBy
|
||||
title: Check if array elements are equal based on function
|
||||
tags: array,intermediate
|
||||
firstSeen: 2020-10-19T22:14:49+03:00
|
||||
lastUpdated: 2020-10-19T22:14:49+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: allUnique
|
||||
title: Check if all array elements are unique
|
||||
tags: array,beginner
|
||||
firstSeen: 2020-10-19T19:47:26+03:00
|
||||
lastUpdated: 2021-01-08T00:23:44+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: allUniqueBy
|
||||
title: Check if all array elements are unique based on function
|
||||
tags: array,intermediate
|
||||
firstSeen: 2020-10-19T22:15:05+03:00
|
||||
lastUpdated: 2021-01-08T00:23:44+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: and
|
||||
title: Logical and
|
||||
tags: math,logic,beginner
|
||||
unlisted: true
|
||||
firstSeen: 2020-05-13T11:35:31+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: any
|
||||
title: Test if any array element is truthy
|
||||
tags: array,beginner
|
||||
firstSeen: 2018-02-14T11:46:15+02:00
|
||||
lastUpdated: 2020-10-18T20:24:28+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: aperture
|
||||
title: Consecutive element subarrays
|
||||
tags: array,intermediate
|
||||
firstSeen: 2020-05-13T13:25:33+03:00
|
||||
lastUpdated: 2020-10-18T20:24:28+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: approximatelyEqual
|
||||
title: Approximately number equality
|
||||
tags: math,beginner
|
||||
firstSeen: 2018-02-14T12:47:13+02:00
|
||||
lastUpdated: 2020-11-01T20:50:57+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: arithmeticProgression
|
||||
title: Arithmetic progression
|
||||
tags: math,algorithm,beginner
|
||||
firstSeen: 2020-10-04T11:37:07+03:00
|
||||
lastUpdated: 2021-10-13T19:29:39+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: arrayToCSV
|
||||
title: Array to CSV
|
||||
tags: array,string,intermediate
|
||||
firstSeen: 2018-06-27T20:26:43+03:00
|
||||
lastUpdated: 2020-11-03T21:55:08+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: arrayToHTMLList
|
||||
title: Array to HTML list
|
||||
tags: browser,array,intermediate
|
||||
firstSeen: 2020-10-08T00:02:45+03:00
|
||||
lastUpdated: 2020-10-20T11:46:23+03:00
|
||||
@ -10,7 +10,7 @@ Converts the given array elements into `<li>` tags and appends them to the list
|
||||
- Use `Array.prototype.map()` and `Document.querySelector()` to create a list of html tags.
|
||||
|
||||
```js
|
||||
const arrayToHTMLList = (arr, listID) =>
|
||||
const arrayToHTMLList = (arr, listID) =>
|
||||
document.querySelector(`#${listID}`).innerHTML += arr
|
||||
.map(item => `<li>${item}</li>`)
|
||||
.join('');
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: ary
|
||||
title: Function arity
|
||||
tags: function,advanced
|
||||
firstSeen: 2018-01-24T13:59:54+02:00
|
||||
lastUpdated: 2020-10-18T20:24:28+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: assertValidKeys
|
||||
title: Assert object keys are valid
|
||||
tags: object,intermediate
|
||||
firstSeen: 2021-07-18T05:00:00-04:00
|
||||
---
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: atob
|
||||
title: Decode Base64 encoded string
|
||||
tags: node,string,beginner
|
||||
firstSeen: 2018-01-17T21:43:21+02:00
|
||||
lastUpdated: 2020-09-15T16:28:04+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: attempt
|
||||
title: Attempt invoking a function
|
||||
tags: function,intermediate
|
||||
firstSeen: 2018-01-28T14:44:40+02:00
|
||||
lastUpdated: 2020-10-18T20:24:28+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: average
|
||||
title: Average of numbers
|
||||
tags: math,array,beginner
|
||||
firstSeen: 2017-12-29T13:29:49+02:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: averageBy
|
||||
title: Mapped array average
|
||||
tags: math,array,intermediate
|
||||
firstSeen: 2018-01-11T12:25:54+02:00
|
||||
lastUpdated: 2020-10-21T21:17:45+03:00
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
---
|
||||
title: bifurcate
|
||||
title: Bifurcate array based on values
|
||||
tags: array,intermediate
|
||||
firstSeen: 2018-02-14T12:13:07+02:00
|
||||
lastUpdated: 2020-11-01T20:50:57+02:00
|
||||
---
|
||||
|
||||
Splits values into two groups, based on the result of the given `filter` array.
|
||||
Splits values into two groups, based on the result of the given `filter` array.
|
||||
|
||||
- Use `Array.prototype.reduce()` and `Array.prototype.push()` to add elements to groups, based on `filter`.
|
||||
- If `filter` has a truthy value for any element, add it to the first group, otherwise add it to the second group.
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
---
|
||||
title: bifurcateBy
|
||||
title: Bifurcate array based on function
|
||||
tags: array,intermediate
|
||||
firstSeen: 2018-02-14T12:13:07+02:00
|
||||
lastUpdated: 2020-11-01T20:50:57+02:00
|
||||
---
|
||||
|
||||
Splits values into two groups, based on the result of the given filtering function.
|
||||
Splits values into two groups, based on the result of the given filtering function.
|
||||
|
||||
- Use `Array.prototype.reduce()` and `Array.prototype.push()` to add elements to groups, based on the value returned by `fn` for each element.
|
||||
- If `fn` returns a truthy value for any element, add it to the first group, otherwise add it to the second group.
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: binary
|
||||
title: Binary function arity
|
||||
tags: function,intermediate
|
||||
firstSeen: 2020-05-13T13:36:36+03:00
|
||||
lastUpdated: 2020-10-18T23:04:45+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: binarySearch
|
||||
title: Binary search
|
||||
tags: algorithm,array,beginner
|
||||
firstSeen: 2020-12-28T12:35:44+02:00
|
||||
lastUpdated: 2020-12-29T13:06:47+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: bind
|
||||
title: Bind function context
|
||||
tags: function,object,advanced
|
||||
firstSeen: 2018-01-24T14:14:49+02:00
|
||||
lastUpdated: 2020-10-18T23:04:45+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: bindAll
|
||||
title: Bind all object methods
|
||||
tags: object,function,intermediate
|
||||
firstSeen: 2018-01-26T14:14:53+02:00
|
||||
lastUpdated: 2020-11-03T22:11:18+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: bindKey
|
||||
title: Bind object method
|
||||
tags: function,object,advanced
|
||||
firstSeen: 2018-01-24T14:22:43+02:00
|
||||
lastUpdated: 2020-10-18T23:04:45+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: binomialCoefficient
|
||||
title: Binomial coefficient
|
||||
tags: math,algorithm,beginner
|
||||
firstSeen: 2018-02-14T12:34:02+02:00
|
||||
lastUpdated: 2020-12-28T13:49:24+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: both
|
||||
title: Logical and for functions
|
||||
tags: function,logic,beginner
|
||||
unlisted: true
|
||||
firstSeen: 2020-05-13T11:35:36+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: bottomVisible
|
||||
title: Check if bottom of page is visible
|
||||
tags: browser,beginner
|
||||
firstSeen: 2017-12-17T17:55:51+02:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: btoa
|
||||
title: Encode string to Base64
|
||||
tags: node,string,beginner
|
||||
firstSeen: 2018-01-17T21:43:21+02:00
|
||||
lastUpdated: 2020-09-15T16:28:04+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: bubbleSort
|
||||
title: Bubble sort
|
||||
tags: algorithm,array,beginner
|
||||
firstSeen: 2020-12-27T21:20:31+02:00
|
||||
lastUpdated: 2020-12-29T12:18:58+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: bucketSort
|
||||
title: Bucket sort
|
||||
tags: algorithm,array,intermediate
|
||||
firstSeen: 2020-12-28T22:11:56+02:00
|
||||
lastUpdated: 2020-12-29T12:22:44+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: byteSize
|
||||
title: Byte size of string
|
||||
tags: string,beginner
|
||||
firstSeen: 2017-12-29T14:30:34+02:00
|
||||
lastUpdated: 2020-10-18T23:04:45+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: caesarCipher
|
||||
title: Caesar cipher
|
||||
tags: algorithm,string,beginner
|
||||
firstSeen: 2020-12-28T20:10:18+02:00
|
||||
lastUpdated: 2020-12-29T12:29:21+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: call
|
||||
title: Call functions with context
|
||||
tags: function,advanced
|
||||
firstSeen: 2017-12-22T21:54:30+02:00
|
||||
lastUpdated: 2021-06-13T13:50:25+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: capitalize
|
||||
title: Capitalize string
|
||||
tags: string,intermediate
|
||||
firstSeen: 2017-12-17T16:41:31+02:00
|
||||
lastUpdated: 2020-11-01T20:50:57+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: capitalizeEveryWord
|
||||
title: Capitalize every word
|
||||
tags: string,regexp,intermediate
|
||||
firstSeen: 2017-12-17T17:55:51+02:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: cartesianProduct
|
||||
title: Cartesian product
|
||||
tags: math,array,beginner
|
||||
firstSeen: 2020-12-28T20:23:47+02:00
|
||||
lastUpdated: 2020-12-29T12:31:43+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: castArray
|
||||
title: Cast to array
|
||||
tags: type,array,beginner
|
||||
firstSeen: 2018-01-23T20:54:12+02:00
|
||||
lastUpdated: 2020-09-15T16:28:04+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: celsiusToFahrenheit
|
||||
title: Celsius to Fahrenheit
|
||||
tags: math,beginner
|
||||
unlisted: true
|
||||
firstSeen: 2020-04-16T11:00:06+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: chainAsync
|
||||
title: Chain async functions
|
||||
tags: function,intermediate
|
||||
firstSeen: 2017-12-17T17:55:51+02:00
|
||||
lastUpdated: 2020-09-15T16:28:04+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: changeLightness
|
||||
title: Change color lightness
|
||||
tags: string,browser,regexp,intermediate
|
||||
firstSeen: 2020-10-30T17:38:31+02:00
|
||||
lastUpdated: 2020-10-31T16:37:54+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: checkProp
|
||||
title: Check property
|
||||
tags: function,object,intermediate
|
||||
firstSeen: 2019-03-17T03:53:00+02:00
|
||||
lastUpdated: 2020-11-01T20:50:57+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: chunk
|
||||
title: Split into chunks
|
||||
tags: array,intermediate
|
||||
firstSeen: 2017-12-17T16:41:31+02:00
|
||||
lastUpdated: 2020-11-03T21:35:12+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: chunkIntoN
|
||||
title: Split array into n chunks
|
||||
tags: array,intermediate
|
||||
firstSeen: 2020-05-04T13:00:46+03:00
|
||||
lastUpdated: 2020-11-03T21:46:13+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: chunkify
|
||||
title: Chunk interable
|
||||
tags: function,generator,array,advanced
|
||||
firstSeen: 2021-03-16T22:50:40+02:00
|
||||
lastUpdated: 2021-03-16T22:50:40+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: clampNumber
|
||||
title: Clamp number
|
||||
tags: math,beginner
|
||||
firstSeen: 2017-12-20T19:19:18+02:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: cloneRegExp
|
||||
title: Clone RegExp
|
||||
tags: type,intermediate
|
||||
firstSeen: 2018-01-01T19:45:47+02:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: coalesce
|
||||
title: Argument coalescing
|
||||
tags: type,beginner
|
||||
firstSeen: 2017-12-17T10:08:55+02:00
|
||||
lastUpdated: 2020-09-15T16:28:04+03:00
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
---
|
||||
title: coalesceFactory
|
||||
title: Argument coalescing factory
|
||||
tags: function,type,intermediate
|
||||
firstSeen: 2017-12-18T12:15:36+02:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
---
|
||||
|
||||
Customizes a coalesce function that returns the first argument which is true based on the given validator.
|
||||
Customizes a coalesce function that returns the first argument which is `true` based on the given validator.
|
||||
|
||||
- Use `Array.prototype.find()` to return the first argument that returns `true` from the provided argument validation function, `valid`.
|
||||
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: collectInto
|
||||
title: Convert function to variadic
|
||||
tags: function,array,intermediate
|
||||
firstSeen: 2017-12-22T05:08:36+02:00
|
||||
lastUpdated: 2021-06-13T13:50:25+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: colorize
|
||||
title: Colorize text
|
||||
tags: node,string,intermediate
|
||||
firstSeen: 2018-01-13T13:36:59+02:00
|
||||
lastUpdated: 2020-11-03T22:11:18+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: combine
|
||||
title: Combine object arrays
|
||||
tags: array,object,intermediate
|
||||
firstSeen: 2020-10-04T00:26:51+03:00
|
||||
lastUpdated: 2020-10-08T02:22:39+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: compact
|
||||
title: Compact array
|
||||
tags: array,beginner
|
||||
firstSeen: 2017-12-14T08:19:15+02:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
@ -14,6 +14,6 @@ const compact = arr => arr.filter(Boolean);
|
||||
```
|
||||
|
||||
```js
|
||||
compact([0, 1, false, 2, '', 3, 'a', 'e' * 23, NaN, 's', 34]);
|
||||
compact([0, 1, false, 2, '', 3, 'a', 'e' * 23, NaN, 's', 34]);
|
||||
// [ 1, 2, 3, 'a', 's', 34 ]
|
||||
```
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: compactObject
|
||||
title: Compact object
|
||||
tags: object,array,recursion,advanced
|
||||
firstSeen: 2020-11-27T13:57:41+02:00
|
||||
lastUpdated: 2020-11-27T13:57:41+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: compactWhitespace
|
||||
title: Compact whitespaces
|
||||
tags: string,regexp,beginner
|
||||
firstSeen: 2018-12-12T19:11:33+02:00
|
||||
lastUpdated: 2020-10-18T23:04:45+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: complement
|
||||
title: Logical complement
|
||||
tags: function,logic,beginner
|
||||
firstSeen: 2020-05-13T11:28:33+03:00
|
||||
lastUpdated: 2020-09-15T16:28:04+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: compose
|
||||
title: Compose functions
|
||||
tags: function,intermediate
|
||||
firstSeen: 2017-12-17T16:41:31+02:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: composeRight
|
||||
title: Reverse compose functions
|
||||
tags: function,intermediate
|
||||
firstSeen: 2018-01-23T22:12:56+02:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: containsWhitespace
|
||||
title: Check if string contains whitespace
|
||||
tags: string,regexp,beginner
|
||||
firstSeen: 2020-03-25T12:37:13+02:00
|
||||
lastUpdated: 2020-10-18T23:04:45+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: converge
|
||||
title: Converge branching functions
|
||||
tags: function,intermediate
|
||||
firstSeen: 2018-02-07T12:23:04+02:00
|
||||
lastUpdated: 2021-01-08T00:23:44+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: copySign
|
||||
title: Copy sign to number
|
||||
tags: math,beginner
|
||||
firstSeen: 2020-10-07T23:52:57+03:00
|
||||
lastUpdated: 2020-10-07T23:52:57+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: copyToClipboard
|
||||
title: Copy to clipboard
|
||||
tags: browser,string,event,advanced
|
||||
firstSeen: 2017-12-31T11:40:33+02:00
|
||||
lastUpdated: 2022-01-11T09:32:04+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: copyToClipboardAsync
|
||||
title: Copy to clipboard async
|
||||
tags: browser,string,promise,advanced
|
||||
firstSeen: 2022-01-11T05:00:00-04:00
|
||||
---
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: countBy
|
||||
title: Count grouped elements
|
||||
tags: array,object,intermediate
|
||||
firstSeen: 2018-01-11T13:45:53+02:00
|
||||
lastUpdated: 2020-11-03T22:11:18+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: countOccurrences
|
||||
title: Count occurrences
|
||||
tags: array,intermediate
|
||||
firstSeen: 2017-12-17T17:55:51+02:00
|
||||
lastUpdated: 2020-10-18T23:04:45+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: countSubstrings
|
||||
title: Count substrings of string
|
||||
tags: string,algorithm,beginner
|
||||
firstSeen: 2020-12-31T13:58:51+02:00
|
||||
lastUpdated: 2021-01-08T00:23:44+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: countWeekDaysBetween
|
||||
title: Count weekdays between two dates
|
||||
tags: date,intermediate
|
||||
firstSeen: 2020-10-11T11:44:44+03:00
|
||||
lastUpdated: 2020-10-20T11:21:07+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: counter
|
||||
title: Counter
|
||||
tags: browser,advanced
|
||||
firstSeen: 2018-05-06T17:55:46+03:00
|
||||
lastUpdated: 2020-11-01T20:50:57+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: createDirIfNotExists
|
||||
title: Create directory if not exists
|
||||
tags: node,beginner
|
||||
firstSeen: 2018-12-12T19:25:16+02:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: createElement
|
||||
title: Create HTML element
|
||||
tags: browser,beginner
|
||||
firstSeen: 2018-01-05T18:21:44+02:00
|
||||
lastUpdated: 2020-10-19T18:51:03+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: createEventHub
|
||||
title: Create event hub
|
||||
tags: browser,event,advanced
|
||||
firstSeen: 2018-01-05T15:07:26+02:00
|
||||
lastUpdated: 2020-09-15T16:28:04+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: currentURL
|
||||
title: Current URL
|
||||
tags: browser,beginner
|
||||
firstSeen: 2017-12-18T11:05:03+02:00
|
||||
lastUpdated: 2020-10-20T11:46:23+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: curry
|
||||
title: Curry function
|
||||
tags: function,recursion,advanced
|
||||
firstSeen: 2017-12-10T15:21:35+02:00
|
||||
lastUpdated: 2020-10-22T20:23:47+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: cycleGenerator
|
||||
title: Cycle generator
|
||||
tags: function,generator,advanced
|
||||
firstSeen: 2020-10-11T17:05:38+03:00
|
||||
lastUpdated: 2020-10-11T17:05:38+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: dateRangeGenerator
|
||||
title: Date range generator
|
||||
tags: date,function,generator,advanced
|
||||
firstSeen: 2021-06-21T05:00:00-04:00
|
||||
---
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: dayName
|
||||
title: Day name
|
||||
tags: date,beginner
|
||||
firstSeen: 2020-10-04T00:31:08+03:00
|
||||
lastUpdated: 2020-11-01T20:50:57+02:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: dayOfYear
|
||||
title: Day of year
|
||||
tags: date,beginner
|
||||
firstSeen: 2018-09-29T13:22:20+03:00
|
||||
lastUpdated: 2020-10-19T18:51:03+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: daysAgo
|
||||
title: Days ago
|
||||
tags: date,beginner
|
||||
firstSeen: 2020-10-06T05:35:23+03:00
|
||||
lastUpdated: 2022-01-30T11:48:07+03:00
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
---
|
||||
title: daysFromNow
|
||||
title: Days from now
|
||||
tags: date,beginner
|
||||
firstSeen: 2020-10-09T02:49:17+03:00
|
||||
lastUpdated: 2022-01-30T11:48:07+03:00
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user