Fix react deprecations.