Refactor to match WebContainer interfaces + requirements