react-breadcrumbs-dynamic icon indicating copy to clipboard operation
react-breadcrumbs-dynamic copied to clipboard

firefox browser getting order error not in ChromeBrowser

Open sridharchary opened this issue 6 years ago • 2 comments

I am adding one attribute(name as:depth) to BreadcrumbsItem and changing order of BreadcrumbsItems. its perfectly working in chrome after reloading successfully. But while testing in firefox it giving rendomly displaying.

BreadcrumbsItem to="/" depth="1" depth="2" depth="3" <BreadcrumbsItem > </BreadcrumbsItem>

to render in order i wrote code in Breadcrumbs <Breadcrumbs separator={ / } item={Link} finalItem={'b'} compare={function(a,b){ if(parseInt(a.depth)< parseInt(b.depth)){ return -1; } return 0; }} />

sridharchary avatar Jan 31 '19 11:01 sridharchary

Hi, please refer to js/es Array::sort() specification about sorting comparision function.

oklas avatar Feb 01 '19 20:02 oklas

Let me know if problem still exists

oklas avatar Feb 01 '19 20:02 oklas