I use react 16. I want to render portal inside my app like that:
<html>
<body>
<div id="app-root">
<div>...My app stuff</div>
<div id="modal-root">... portal stuff</div> <-- portal content
</div>
</body>
</html>
But official doc recommends render portal next to, not in app.
<html>
<body>
<div id="app-root"></div>
<div id="modal-root"></div>
</body>
</html>
Is it the only correct way to use the portal?