I've had success with a short take-home task and then an interview asking them to talk through the code/potentially modify it/discuss the approach.
They get time to prepare and think about the problem. Because it's a familiar context, you can ask for more real-world alterations, discuss deployment meaningfully, etc.