I personally lost weight by doing strength training mainly (1h, 3 times a week), but there were some cardio included along each week like running, swimming or sometimes aerobic training with my girlfriend, but these cardio trainings max 2 times a week 🙂 I strongly encourage you to incorporate both and I would say that if you are a man you should do more strength training (it will raise your testosterone level and it will burn fat as well) and I would recommend more aerobics training if you are a woman (but remember about strength training as well! It is very important to strengthen your muscles even if you don't want to make them visible).
I'm trying to lose weight too I try to variate my week some days I feel like doing 30 full body cardio workout other days I do strength workouts and some days I gaver them there are a lot of videos that gather cardio and strength workouts they both burn calories so they help with loosing weight
Inmy opinion, it would be better to mix those. For example, if you go to the gym, you can do an ab workout and run on the treadmill. Mixing cardio and sstrenght training into a workout can help you maintain your energy for longer, build muscle, and lose fat and weight🥰