Created
May 4, 2025 02:13
-
-
Save henshaw/47bb8a0d91a8bb87420b0e2f85a91cb8 to your computer and use it in GitHub Desktop.
Custom WordPress block used for rating summaries
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <div class="ratingsummary"> | |
| <div class="rating"> | |
| <div><span title="Rating: <?php block_field( 'rating' ); ?> out of 10"><?php block_field( 'rating' ); ?></span></div> | |
| </div> | |
| <div class="pros"> | |
| <h2>What I liked most</h2> | |
| <?php block_field( 'strengths' ); ?> | |
| </div> | |
| <div class="cons"> | |
| <h2>Could be better</h2> | |
| <?php block_field( 'shortcomings' ); ?> | |
| </div> | |
| </div> |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Referenced: Embracing the block: Why it’s finally time to switch to Gutenberg