It's both but great composition can be ruined by poor technically executed photo. Like wise a technically executed photo can be boring.
I believe minor technical errors will be ignored by a strong composition.
Searching my blog for "composition" will have many posts.
This link has another view -> I'm against teaching composition rules. Rigorous following on the rules of composition leads to a lack of creativity.
I believe that they are guides but it is more helpful to actually show examples of good composition.
This discussion from Light Stalking is more informative than "rules" https://www.lightstalking.com/composition-mistakes/