I think a Set would work nicely here, if there's not a specific reason to want a JS object.