This is the same reason I offer candidates remote screen share-based technical assessments. Part of what makes an effective engineer is mastery over tools: by putting you into Coderpad or Hacker Rank type tools, I'm handicapping you.
Not everyone opts for that (maybe their local environment is messy, or they only have a locked down work device, etc), but I always make it an option.
I've learned many things over the years watching other experts in their local environments as an interviewer. New packages, new shortcuts, new helper apps, ...