Skip to content

Commit ff60bb6

Browse files
committed
Glossary termify component shadowing and shadowing and update definition
1 parent 4e334b6 commit ff60bb6

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

docs/glossary.md

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -182,9 +182,17 @@ Configuration registry
182182
183183
In Plone core, [`plone.app.registry`](https://pypi.org/project/plone.app.registry/) provides Plone UI and `GenericSetup` integration for [`plone.registry`](https://pypi.org/project/plone.registry/), which in turn implements a configuration registry for Zope applications.
184184
185-
Shadowing (Volto)
186-
Webpack provides an "alias" mechanism, where the path for a module can be aliased to another module.
187-
By using this mechanism Volto enables customization (file overrides), similar to `z3c.jbot.`
185+
component shadowing
186+
shadowing
187+
Volto uses a technique called component shadowing to override an existing Volto component with our local custom version, without having to modify Volto's source code.
188+
189+
Volto's source components are located in the filepath stem of `omelette/src/components/`.
190+
Custom components that shadow Volto's source would be located in the filepath stem of `src/customizations/components/`.
191+
Shadow components would have the same filepath as Volto's source compenents, excluding the stem.
192+
Thus `omelette/src/components/theme/Header/Header.jsx` would be shadowed by `src/customizations/components/theme/Header/Header.jsx`.
193+
194+
Webpack provides an alias mechanism that allows component shadowing in Volto, where the path for a module can be aliased to another module.
195+
By using this mechanism of file overrides, or component shadowing, Volto enables customization, similar to `z3c.jbot.`
188196
189197
Razzle
190198
A tool that simplifies SPA and SSR configuration for React projects.

0 commit comments

Comments
 (0)