How to use the remeda.toPairs function in remeda

To help you get started, we’ve selected a few remeda examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github alternate-file / vscode-alternate-file / src / engine / Projections.ts View on Github external
export const projectionsToAlternatePatterns = (
  projections: t
): AlternatePattern.t[] => {
  const pairs = R.toPairs(projections) as ProjectionPair[];
  const allPairs = R.flatten(pairs.map(splitOutAlternates));

  return allPairs.map(projectionPairToAlternatePattern);
};

remeda

A utility library for JavaScript and Typescript.

MIT
Latest version published 15 days ago

Package Health Score

95 / 100
Full package analysis