mirror of
https://github.com/react/react-native-devtools-frontend.git
synced 2026-10-21 21:47:18 +08:00
DISABLE_THIRD_PARTY_CHECK=new npm module causes package-lock change We can get rid of a custom script and use ESLint for these rules. Additionally this means editors will highlight the issue in the editor. Change-Id: I552b52e7f07b4e7430b3f685dbc3b5fad36ffff2 Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2052167 Reviewed-by: Paul Lewis <aerotwist@chromium.org> Commit-Queue: Jack Franklin <jacktfranklin@chromium.org>
26 lines
924 B
JavaScript
26 lines
924 B
JavaScript
import _curry1 from './internal/_curry1.js';
|
|
import _dispatchable from './internal/_dispatchable.js';
|
|
import _xdropRepeatsWith from './internal/_xdropRepeatsWith.js';
|
|
import dropRepeatsWith from './dropRepeatsWith.js';
|
|
import equals from './equals.js';
|
|
|
|
/**
|
|
* Returns a new list without any consecutively repeating elements.
|
|
* [`R.equals`](#equals) is used to determine equality.
|
|
*
|
|
* Acts as a transducer if a transformer is given in list position.
|
|
*
|
|
* @func
|
|
* @memberOf R
|
|
* @since v0.14.0
|
|
* @category List
|
|
* @sig [a] -> [a]
|
|
* @param {Array} list The array to consider.
|
|
* @return {Array} `list` without repeating elements.
|
|
* @see R.transduce
|
|
* @example
|
|
*
|
|
* R.dropRepeats([1, 1, 1, 2, 3, 4, 4, 2, 2]); //=> [1, 2, 3, 4, 2]
|
|
*/
|
|
var dropRepeats = /*#__PURE__*/_curry1( /*#__PURE__*/_dispatchable([], /*#__PURE__*/_xdropRepeatsWith(equals), /*#__PURE__*/dropRepeatsWith(equals)));
|
|
export default dropRepeats; |