Snippets: Add Print Button to Social Share

add_filter( 'wpex_get_social_items', function ( $items ) {
	$items['print'] = array(
		'site'       => 'Print',
		'label'      => 'Print',
		'li_class'   => 'custom-print',
		'icon_class' => 'ticon ticon-print',
		'href'       => '#print',
	);
	return $items;
} );

add_action( 'wp_enqueue_scripts', function() {

	$script = '
	jQuery( document ).ready(function() {
		jQuery( ".wpex-social-share li.custom-print a" ).click( function() {
			window.print();
		} );
	} );';

	wp_add_inline_script( 'jquery', $script );

} );
All PHP snippets should be added via a child theme's functions.php file.