Refactor Navigation block render
function to be open for extension
#52470
Labels
[Block] Navigation
Affects the Navigation Block
[Type] Code Quality
Issues or PRs that relate to code quality
Over the years the
render_block_core_navigation
function has grown to be pretty unwiedly. Making any changes is prone to error and there's little in the way of direct test coverage (we do have e2e tests).Let's start an incremental refactor with lots of small PRs which break this function down into discreet functions which do one thing. As this process occurs let's add PHPUnit tests to provide test coverage for the smaller functions.
When complete the main
render_block_core_navigation
should be easy to reason about and extend.The text was updated successfully, but these errors were encountered: