Details
-
Story
-
Resolution: Fixed
-
Neutral
-
None
-
None
-
None
-
-
Empty show more show less
-
DevX 44, DevX 45
-
5
-
Yes
Description
Besides react built-in context (React.createContext()), supports another way by using a global singleton that can share data between components:
- Consider moving unchanged data in 1 js singleton (componentMappings, fallbackComponent, devMode)
- And easy changed data in another js (content from page, templateAnnotations)
Â
Â
AC: Check and update all sample spa project that used EditorContext.js
Â
Reference code: ComponentConfig.js, ContextSingleton.js from propsal PR: https://git.magnolia-cms.com/projects/MODULES/repos/frontend-helpers/pull-requests/220/diff#samples/next-js-13-with-react-editor-new/packages/react-editor-2/src/utils/ContextSingleton.js
Checklists
Acceptance criteria
Attachments
Issue Links
- to be documented by
-
MGNLFE-628 DOC: Describe React SharedContext
-
- Closed
-
1.
|
Implement |
|
Closed | Phong Le Quoc | ||||||||
2.
|
Review |
|
Closed | Oanh Thai Hoang | ||||||||
3.
|
PiQA |
|
Closed | Oanh Thai Hoang |
|
|||||||
4.
|
QA |
|
Closed | Anh Vu | ||||||||
5.
|
Prepare a sample next 13 project for support piQA to check if we need to remove createContext completely or not |
|
Closed | Oanh Thai Hoang |
|