Q:

How Can I uniquely identify users device from my javascript code?

I am making a categorized mapping platform and I want my users to submit anonymous data. So I want any javascript method so that I can Identify my users uniquely.

A:

To anonymously identify a "user", auto-assign a new unique number/string to new users and create a persistent cookie with the value.
You can now recognize that "user" any time. Well, until the user clears all the cookies, which happens automatically if the user is browsing in privacy mode.
Remember that creating cookies must be reported to users in EU. See e.g. EU Cookie Law.

