What's wrong with Shopware docs
Hi! I am a plugin developer for Shopware 6 shops. FInally a found a place to tell how impossibly bad the SHopware docs are. It's almost he worst documentation of everything I ever worked with. Here a re the main problems: take for example the custom storefront js article.
- You really explain what is window.innerHeight and window.pageYOffset, but do not tell what is the lifetime of the plugin class instance? Really? It's one of the most important things here. Only after 2 hours of debugging I finally found that out by myself. If a person decides to write a Shopware plugin, chances that he or she is not 4 years old and know about window.innerHeight are pretty high, but the really important info is nowhere to find
- The new registration of custom entites with php Attributes. You mention JSON filds and serialization. Guess how much time I spent figuring out that those serializers must be registered in a special way to work. And still I have no idea about when the serialization and deserialization actually happens. No word about it. And how to create a migration from those new entity definitions? Good luck trying to find it and then writing the sql by hand.
- Shopware php events... Countless many times I needed a hook on some event and there is no place in the docs where they are listed. I know that Shopware is opensource and Github has an ability to look up something in the code. But things like this MUST be documented at least somewhere because almost all the plugins need them, it is also one of the central concepts when writing a plugin. Finally you added at least the checkout event list, at least... Not in a thousand years
- You want the types when working with repositories and Shopware global object when creating some administration module? Or that the nested entities should be not of array type but an EntityCollection? Shopware team considers it a secret and that's why they do not tell it in the docs. Try it out, debug for 8 hours straight with 400 response code and then find this out.
These things are the most important but there are countlessly many more. Basically, writing a plugin turns out to be digging in the Shopware repository for hours trying to find the definitions you need. I really wish things get better
External contributor here: I understand most of you points but as I also wrote parts on the "Finding events" page : https://developer.shopware.com/docs/guides/plugins/plugins/framework/event/finding-events.html I see though, that it is not a compedium of all events but it is a good guide how to get into the lots of dynamically named events. Did you stumble upon this page? I know the search is sometimes tricking you into not finding specific pages ^^'
External contributor here: I understand most of you points but as I also wrote parts on the "Finding events" page : https://developer.shopware.com/docs/guides/plugins/plugins/framework/event/finding-events.html I see though, that it is not a compedium of all events but it is a good guide how to get into the lots of dynamically named events. Did you stumble upon this page? I know the search is sometimes tricking you into not finding specific pages ^^'
Oh, thanks, I didn't see it. I tried hard to look for all the other pages mentioned in the issue beacuse maybe I just did not find the right page, but I couldn't find them. My point is that rather on creating a whole guide page for everything with details, it would be enough to at least add some reference, documented class lib or maybe at least some hints in the code comments of Shopware. It would make life of so many devs so much easier. And rather then explaining in the guides, what console.log does, better spend this time adding an api reference to some new class. Better docs coverage would be better then uncomplete documentation but so detailed