Unless there’s something I want to draw attention to, I set a larger depth of field and focus on the closest point of the yoyo. This means the whole thing is in focus. You can set a tiny aperture if you’re using a tripod, resulting in sharp photos of the whole yoyo.
If you don’t have a manual mode on the camera (it’s a phone or a point and click) just make sure there’s heaps of light. The camera will automatically back off on the aperture in order to not blow out the photo. It’s hard to get depth of field with those kinds of cameras anyhow. Then just focus on whatever the autofocus wants to grab (usually the front).
Back to the first scenario, though… the only time to do hub in focus, front of rims out of focus is when you specifically want to draw attention to the engraving or hub features. Otherwise it just makes the whole photo kinda weird in my opinion. When in doubt, focus on the front.