So I'm trying to make a portal effect for an animation, and unfortunately the only way i know of for doing this effect is by using layers and the compositor in 2.79, which were replaced with the collection system in 2.8:
View and Render Layers are working similar to 2.79 but sadly EEVEE can't use Material/Object Index Pass. So you can't make a portal using this method. Read more here and watch video from the links: Blender 2.8 - Object index pass in Eevee
How to replicate it using different method
I've created two Collections - Portal and Behind_portal and also two View Layers accordingly.
To exclude Collection from View Layer - select it and press E or RMB > View Layer > Set Exclude.
In Compositing I've used Color Key to "remove" color of Holdout shader assigned to portal. I've also scaled a bit result and blurred it, as Color Key is not 100% precise.