how to solve react spinners unique "key" prop warning?

210 Views Asked by At

I am working on react spinners, I am added a simple loader BeatLoader as react-spinners doc say, but i am getting unique "key" prop warning , I know it has not effect my application but it has to solve .

import React from "react";
import BeatLoader from "react-spinners/BeatLoader";

const SelectBoxLoader = Props => {
    return (
        <div className="sweet-loading">
            <BeatLoader
                size={15}
                margin={2}
                color={"#62842C"}
                loading={Props.loading}
            />
        </div>
    );
};

export default SelectBoxLoader;

my jsx file is link that, How can i remove unique "key" prop warning from react-spinners/BeatLoader

full warning -

Warning: Each child in a list should have a unique "key" prop. See https://reactjs.org/link/warning-keys for more information.
    at span
    at EmotionCssPropInternal
    at Loader (http://localhost:8088/_next/static/chunks/pages/ship-for-me.js?ts=1618980005007:101089:47)
    at div
    at SelectBoxLoader (http://localhost:8088/_next/static/chunks/pages/ship-for-me.js?ts=1618980005007:114691:22)
    at form
    at div
    at div
    at div
    at div
    at div
    at ShipForMe (http://localhost:8088/_next/static/chunks/pages/ship-for-me.js?ts=1618980005007:114892:78)
    at div
    at div
    at ShipForMePage
    at div
    at div
    at SiteLayout (http://localhost:8088/_next/static/chunks/pages/_app.js?ts=1618980005007:77713:23)
    at CartProvider (http://localhost:8088/_next/static/chunks/pages/_app.js?ts=1618980005007:80873:77)
    at ProductsProvider (http://localhost:8088/_next/static/chunks/pages/_app.js?ts=1618980005007:81522:73)
    at SettingsProvider (http://localhost:8088/_next/static/chunks/pages/_app.js?ts=1618980005007:81667:73)
    at AuthProvider (http://localhost:8088/_next/static/chunks/pages/_app.js?ts=1618980005007:80677:73)
    at MoveOnApp (http://localhost:8088/_next/static/chunks/pages/_app.js?ts=1618980005007:81967:24)
    at ErrorBoundary (http://localhost:8088/_next/static/chunks/main.js?ts=1618980005007:146:47)
    at ReactDevOverlay (http://localhost:8088/_next/static/chunks/main.js?ts=1618980005007:250:23)
    at Container (http://localhost:8088/_next/static/chunks/main.js?ts=1618980005007:12274:5)
    at AppContainer (http://localhost:8088/_next/static/chunks/main.js?ts=1618980005007:12751:24)
    at Root (http://localhost:8088/_next/static/chunks/main.js?ts=1618980005007:12867:25)

link that

0

There are 0 best solutions below