The current architecture for modifications is a bit weird ... what about introducing a consumer plugin.
What can a consumer plugin do
- Register base fields for storage reasons ...
- Provide a way to show information on the consumer list
- Maybe more?
Some thoughts?
| Comment | File | Size | Author |
|---|---|---|---|
| #6 | 2906900-image_style-6.patch | 489 bytes | e0ipso |
| #6 | 2906900-6.patch | 2.02 KB | e0ipso |
Comments
Comment #2
e0ipsoSounds good!
My only concern would be that we'd be boxing ourselves in that list of features. The current pattern implements the standard hooks for altering fields, which is what I'd look up first when debugging the module.
Do you want to take a quick stab at what that plugin would look like?
Comment #3
dawehnerYou are totally right, though to be honest, we could still document that you can do whatever the hack you need to do, if you want to, but here is a nice and easy way to do the common things ... does that make sense?
I'm gonna give it a quick try.
Comment #4
dawehnerComment #6
e0ipsoMerged with small changes.
Comment #7
e0ipsoSorry, the above files are interdiffs, not patches.
Comment #8
e0ipsoAlso merged the companion patch to the image styles. See http://cgit.drupalcode.org/consumer_image_styles/commit/?id=ab1d366
Comment #9
e0ipsoComment #10
dawehnerNice!
Comment #12
dawehnerComment #13
e0ipsoMaybe when we get back on this, we can have a nice UI autogenerated. I did this in the past for the seed code on the Social API initiative.
See for instance the example here: https://www.drupal.org/docs/8/contrib/social-api/social-widgets
Comment #14
dawehnerI'm been talking with @bojanz about what they call entity traits. There you can configure "traits" per bundles, which provide additional fields automatically. Behind the doors they are using configurable fields instead of base fields, given all the complexity potentially involved with altering the existing database table.
Comment #15
e0ipso@dawehner I'm not sure I have enough context for that. Is this something you'd be interested to take on, or provide more context for others?
Comment #16
e0ipsoWe've been running with the current architecture for a while without significant issues.