Needed for portal#529 (closed).
See issue on react-hook-form repository for reference.
react-hook-form