I am currently on a node in the project and wish to use helpers, and have looked at this link:
https://developer.shopware.com/docs/guides/plugins/plugins/administration/using-utils
I would like a helper for translating fragments read from the database and maybe some other functionality to make the project more manageable (maybe there is an easier way, I need to use quite a few functions to translate).
As the article said, I also looked at the Shopware object, but I don't know how to use this object to access a function.
Thanks for the help.
See the documentation on How to add fragments in the admin interface. You can use the Vue I18n plugin to automatically translate snippets into the currently selected language.
The functions of this plug-in are globally available in the component without using additional auxiliary functions.
For
snippet
entities, you can injectsnippetSetService
to get the translation by its key.