-
Task
-
Resolution: Unresolved
-
Should have
-
None
-
None
-
Block: Media
Following https://jira.greenpeace.org/browse/PLANET-4535 (based on https://jira.greenpeace.org/browse/PLANET-4534),
split/reorganize Media block scripts in assets/src/blocks/{Blockname} and assets/src/styles/blocks/{Blockname} to this structure :
- assets/src/blocks/{Blockname}/{Blockname}Script.js instantiates a block on the frontend side
- assets/src/blocks/{Blockname}/{Blockname}EditorScript.js instantiates a block editor, in the gutenberg editor
- assets/src/styles/blocks/{Blockname}/{Blockname}Style.scss is used to style the block on frontend
- assets/src/styles/blocks/{Blockname}/{Blockname}EditorStyle.scss is used for editor specific styles
A generic method you can follow is available in this PR https://github.com/greenpeace/planet4-plugin-gutenberg-blocks/pull/591#user-content-genericmethod
- clones
-
PLANET-6156 Split Spreadsheet block JS/CSS code
- CLOSED
- has to be done after
-
PLANET-5662 Use Preact instead of core WP React on the frontend
- OPEN
- relates to
-
PLANET-4534 Perf: Split frontend JS into critical and deferrable
- OPEN