add_shortcode('show_current_user_id', 'renderCurrentUserId');
function renderCurrentUserId($atts){
$user_id = get_current_user_id();
if(!empty($user_id)){
echo $user_id;
}
else echo '[show_current_user_id]';
}
This will be the shortcode
[show_current_user_id]
And I can't show userid besides that hello icon because there is no filter hook on which I can write custom code
This code you have to add in wplms customizer plugin, and wherever you use this shortcode it will start showing the current logged in user id