The strategy for choosing the optimum diaphragm
Find the aperture value at which your lens shows the best sharpness, and use this value whenever possible (most often it is f/8 or so).
If you don’t have enough light, or if you want to highlight the main subject using a shallow depth of field, increase the size of the aperture, but try not to open it completely unnecessarily.
If the need has come, feel free to open the diaphragm and do not worry about it. In situations where you may need it, the aperture value is not the most important factor limiting the sharpness of images. The wiggle spoils the image much more ruthlessly than any lens aberrations.
If a large depth of field is required, cover the aperture, but not further than f / 11 for wide-angle lenses and f / 16 for telephoto lenses.
If you still lack depth of field, which shouldn’t happen often, use f/16 for wide-angle lenses and f/22 for telephoto lenses. It is not necessary to clamp the aperture more strongly in any case – you will pay for an increase in the grip by a too noticeable drop in the overall sharpness.
That’s all. Knowing about the weaknesses of your equipment allows you to avoid situations in which they will appear, which means that you can more effectively exploit its strengths.