eugene-petrov / magento2-plugin
Magento 2 plugin example
Installs: 0
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
Type:magento2-module
Requires
- php: ^7.2.0
This package is auto-updated.
Last update: 2024-09-21 18:49:45 UTC
README
Snippet_Plugin
Problem: you need to change any (almost any) public method.
Here you can find more about plugins.
To enable this module execute:
php bin/magento --clear-static-content module:enable Snippet_Plugin
php bin/magento setup:upgrade
Snippet\Plugin\Plugin\Frontend\ModifyHeader file is an example of around and after plugins. 'Around' does nothing. While 'after' wraps into parentheses welcome message like this:
(Default welcome msg!)
Snippet\Plugin\Plugin\Frontend\ModifyBreadcrumbs file is an example of 'before' option. E.g. on detail product page breadcrumbs will look like this:
(Home) > (Test Product)