Make sure JS Code Hints list exact matches first

This PR fixes issue #3971.