A sample module that show what and how to use instead of deprecated Registry
class
since Magento 2.3.
This module provides 2 service classes as example:
- get current product;
- get current category;
Also it has as example the situation when one needs to ad a "Back to category" link on the product page.
The module is part of a post on Atwix's blog. Check it out and read the full story of the module.