Guzzle is a great HTTP Client, but it can be difficult to figure out how to get access to its error messages. I've put together a blog post explaining how to catch GuzzleException, and retrieve the full response from the remote server, making debugging Guzzle errors much easier:
I had some serious form caching with a custom form that sets a few of my module's config settings. Normally the config form would be reserved for an admin/settings page, but with this project I don't want the users to access Drupal's back-end. Instead, I've rebuilt most of the necessary back-end config forms on the front-end, so they can still make certain config changes.
^^ This lead to some serious caching issues;
Most caching solutions I found centered around using render arrays with markup elements, but nothing for form element render elements.
In D8, I have a content type with several fields that must exist, but may be used rarely (for now).
I've figured out how to apply a custom stylesheet to the admin-side form.. but I'm not sure how to add a minimize/expand option to certain fields. I'm looking for something just like the "edit summary" to expand or collapse a field.
I know there's a module for putting field groups that can be minimized, but I don't want groups. This is also Not a conditionally hidden field.
I just want the person posting to be able to show/hide a field that is defaulted to hidden.