New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

array-unique-reactjs

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

array-unique-reactjs

Npm Package for convert data to unique array.

latest
Source
npmnpm
Version
1.0.3
Version published
Maintainers
1
Created
Source

Array Unique Reactjs

Npm package that works to convert data to unique arrays. In other words the package to remove the existing data duplication in the data array.

Example

import getUnique from "array-unique-reactjs";

const prizelips = [
  {
    title: "40M",
    price: 5000,
  },
  {
    title: "100M",
    price: 30000,
  },
  {
    title: "350M",
    price: 100000,
  },
  {
    title: "1B",
    price: 100000,
  },
  {
    title: "2.5B",
    price: 200000,
  },
];

const uniquePrize = getUnique(prizelips, "price");

function Test() {
  return (
    uniquePrize.map((item) => console.log(item.price))
    // Output : 5000, 30000, 100000, 200000
  );
}

Keywords

unique-array-data

FAQs

Package last updated on 12 Jul 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts