Skip to content

Instantly share code, notes, and snippets.

@hivepress
Created July 23, 2022 23:16
Show Gist options
  • Select an option

  • Save hivepress/893af2245c6d4c7ff18b2db112fa4a4a to your computer and use it in GitHub Desktop.

Select an option

Save hivepress/893af2245c6d4c7ff18b2db112fa4a4a to your computer and use it in GitHub Desktop.
Add custom CSS class to the HivePress page wrapper #hivepress #themes
<?php
add_filter(
'hivepress/v1/blocks/page',
function( $args ) {
return hivepress()->helper->merge_arrays(
$args,
[
'attributes' => [
'class' => [ 'my-custom-wrapper' ],
],
]
);
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment