If you have limited coding skills, I would recommend finding a plugin for that.
If you feel comfortable editing the code, then give the solution you mentioned a try 🙂 But please be noted, if any issue occurs, you would have to contact that author for a fix.
I understand. I will likely at least try the wplogout solution still, either by myself and/or with the help of a developer. I prioritize speed and performance over some easier or more user friendly way to get the social sharing button.