"write code during interview" was always about real coding, using computer. No paper, no whiteboard, the best way to do it is to give the candidate access to some real code, like a company's internal project, and real task, like a nasty bug to solve, or a small new feature to implement.