There is no "better"
Defense is basically "All or nothing".
If they can overcome your numbers, it's "All"
If they cannot, it's "nothing"
Resist just says "Take a specific amount of the overall damage"
So if you have 40% resist, and take 100 poiints of damage, you make 40% go away and only take 60 damage.
In both cases, you can still take damage, it just makes dropping dead take LONGER.
IDEALLY, you want lots of BOTH.
If you're NORMALLY a "squishy", Defense tends to return more value in the long run. However, you can still be subjected to "drop dead" and cascading defense failures.
With Resistance, you'll still have problems with accepting damage inflicted, especially if you have heavy Resist debuffs stacking on you as well.
There's no such thing as a free lunch.