Although I agree with what was said, I feel like this discussion left out some significant considerations. (FYI...This comes a decade of developing and supporting enterprise DW using SSIS and another decade using several other ETL tools).
First, lets consider what they do...Dataflows give full potential of any SSIS dataflow toolset with a ton of tools included as well as add-ons (e.g. datatype transformation, BDD for parallelism, etc). SqlTask just runs TSQL for you - meaning whatever feel like coding into inline SQL or running stored proc. For that task you're just using SSIS as a calling program and nothing more.
Dataflows give visibility into where your ETL processing is at. Hmm, so isn't that "why" you are using an ETL tool in the first place? Think about it. It's that graphical insight and standardization. Otherwise just code ton of stored procs and geek out. Lay on that technical debt and job security. But dataflows not only make it graphical, create some standard interface for the next person to support, but show you data as it flows instead of just sitting there spinning until its done. And if you're running dynamic code and store it in a variable for the dataflow you can see the SQL that was run. That's massive. Then there's the metadata checking SSIS does with a dataflow to tell you when things change. SqlTask will likely just blow up if metadata changes.
This is especially true if you're using BiXpress (which I would NEVER ever ever use SSIS without and if you're not using BiXpress ask yourself, "why the heck not?!"...there's multitude of benefits of Bixpress - email me if questions...and no I'm NOT a consultant).
So like in all things IT and like what was said, it depends. I still use SqlTasks to move from point A to B IF I'm on the same database AND it proves significantly faster. I prefer dataflows to hard coding insert/selects but sometimes performance just demands a simple insert/select.
Note I said database and not server. Folks welcome to the cloud....if you use Azure SQL or Synapse DW or SQL managed instance you're basically contained inside of a single database. If you're not there yet you will be so go ahead and act like you're there so you don't cause issues when migrating.