DEV Community

Discussion on: Add a unique id and use it as a key

Collapse
 
ahyagoub40 profile image
Ahmed Yagoub

Correct,
can probably 'cherry pick' the method
npm i --save lodash.uniqueid
and import it in the file as so
import uniqueId from 'lodash.uniqueid'
The main reason I went with lodash because it might already be used in the project, if it is not, I agree with you on using a dedicated package
Thanks for reading and for your comment