Last active
September 23, 2019 09:41
-
-
Save mariusghitulescu/6e8051bbf864e015b4ec031d56e2dca3 to your computer and use it in GitHub Desktop.
Disable JSON-LD added by Yoast SEO on post type
This file contains 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
function disable_schema_on_post_type( $post_type ) { | |
if ( $post_type == 'post' ) return false; | |
} | |
add_filter( 'wpseo_json_ld_output', 'disable_schema_on_post_type', 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment