Update code to new renderComponentToString API