| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
Codecov ReportAll modified and coverable lines are covered by tests ✅ Additional details and impacted files @@ Coverage Diff @@
## master #88 +/- ##
=======================================
Coverage 97.80% 97.80%
=======================================
Files 10 10
Lines 228 228
Branches 58 58
=======================================
Hits 223 223
Misses 4 4
Partials 1 1 ☔ View full report in Codecov by Sentry. |
Sorry, something went wrong.
Documents the `slotOptions.mergeProps` option to change the behavior of `PluginSlot` components to merge custom attributes with existing props on widgets.
There was a problem hiding this comment.
It's awesome to see more documentation like this! One little comment.
Sorry, something went wrong.
| ``mergeProps`` | ||
| '''''''''''''' | ||
|
|
||
| When enabled, this option will merge custom/overridden attributes with existing props passed to the widget, as opposed to passing these attributes to the widget via a ``content`` prop. This is especially useful when using a ``PluginSlot`` to support any custom attributes as well as handle special cases such as merging of custom class names with existing class names. |
There was a problem hiding this comment.
It might be nice to have a short description of the default (mergeProps: false) behavior here. I could see someone reading this and thinking, "as opposed to what?"
Sorry, something went wrong.
There was a problem hiding this comment.
This is alluded to in the above "..., as opposed to passing these attributes to the widget via a content prop.". I suppose this could be more clearly communicated, though 👀
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
In the README, documents the slotOptions.mergeProps option to change the behavior of PluginSlot components to merge custom attributes with existing props on widgets.
Preview
Also updates existing code blocks to use javascript syntax highlighting.