If you never met before z3c.jbot, let simply say: this is a toy that commonly make happy the themer of your team. It simplify a lot the customization of a single template inside the Plone universe.
The use of z3c.jbot give you some little performance cost, and commonly you can do stuff without it, however it's use require less development time most of times.
What I learn from the David's comment, is what the official documentation of z3c.bot report in a simple sentence:
CMF objectsWhat is amazing there in the part that say "Any skin-object". Later we will show two great examples.
Any skin-object (e.g. images, templates) on the file system (directory views) can be overridden.
Complex skins layers subfolders
Maybe Plone 5 (or 6, or 7) won't use the CMF skins technology. However today the CMF skins is still a reality.
What's the problem of skins? Commonly no-one: customize an object in the skins layer is very simple, but only if the object itself isn't in a skin subfolder.
What's the problem with subfolders? Well, the problem is always the customization. To customize the object in the sublayer "/foo/object", you need to customize also the foo folder, putting all this in your personal skins layer. But in this way you also need to customize all other skins object in the foo folder.
So why a product developer sometimes register a single skins layer with subfolders instead of register multiple layers, or keep all resources in a flat simple layer?
Because sometimes you need to put into Plone external resources, that commonly are found as a folder tree structure.
I will show two main examples:
- Archetypes widgets
langs (dir)I had only a couple of experiences customizing TinyMCE and I was forced to develop a new plugin both the times. Why? Because commonly you need to change something not in the skins layer root (where customizing is easy), but in one of the plugins subsection.
So, as I sayd, a way is to develop another plugin, that (for example) will replace the basic plonelink ones. You need copy and paste all the plugin code, then you change what you need.
More or less you have created a plugin branch... when another version of TinyMCE will be released, you are forced to check your code for find any changes you need to merge in your plugin...
We will take only this file into consideration:
Products/TinyMCE/skins/tinymce/plugins/plonelink/editor_plugin.jsHow to change only this file without replacing the whole plugin?
First of all, we register the z3c.jbot folder.
Products.TinyMCE.skins.tinymce.plugins.plonelink.editor_plugin.jsVery easy! We customized a single file without creating a clone-plugin!
Another evil task of the Plone universe is when you need to customize an archetype widget. Why? I bet you know the answer... because all widgets are stored in a skins subfolder:
skins/archetypes/widgets/...Change the template used for a widget is simple. Create a new template for a widget is easy... however is not so easy to change the default template for all widget of a kind.
Let show an example: imagine you need to customize the file widget, that is all stored in the file.pt template:
Products/Archetypes/skins/archetypes/widgets/file.ptAs before, we can simply put our customized file in the jbot_templates folder. The file name will be:
Again, this is simple, but only thanks to z3c.jbot!