1

Can you elaborate on the performance hit when using GUIDs as keys in Javascript

Suppose I have 50 thousand objects in a collection like this:

{
"f9b45f79-303d-4752-9023-d29368bb7345": {...}
"f9b38s32_31d4_acc7_08bd_a12ee8ba712a": {...}
...and so on
}

Is it acceptable to use such long strings as keys? Does it pose some performance hit or is it negligible? How does javascript perform comparison when accessing keys? Is the comparison char by char?

RobertPorter
  • 542
  • 6
  • 16

0 Answers0