Created by: mistic100
Follow up of #32941
This commit exports exports all the DOM utils into a domUtils
property, to be able to use them in thrid party JS plugins.
Motivation : The plan is to allow third party plugins to integrates as best as possible into Bootstrap system. Previously this was done through jQuery. But now Bootstrap is basically starting from scratch and locking itself.
- Without
Data
, third party plugins cannot interact with core and other plugins because the map storing instances is private. - Without
EventHandler
, third party plugins will never be able to have a similar event system, neither seamlessly integrate with jQuery when present. This is IMHO critical because it will lead to a scatter of patterns, namings, param handling, etc. -
SelectorEngine
andManipulator
are bonuses, they are not necessary.
Usage : Since 2014 I develop Bootstrap Confirmation and always tried to stick to Bootstrap patterns, sometimes refusing changes because it would be incompatible with Popover behavior. I wouldn't like to offer a degraded v5 migration.
What next :
I think Bootstrap would benefits a documentation, or a least an introduction, to plugins creations, perhaps on the Extend page.
Unfortunately I don't know enough internals to propose somthing.