Ball never reached the line of scrimmage and with no eligible receiver in the area is intentional grounding, intentional grounding penalty from the end zone is a safety.
This post is the correct answer.
RULE 8 FORWARD PASS, BACKWARD PASS, FUMBLE
SECTION 2 INTENTIONAL GROUNDING
ARTICLE 1. DEFINITION. It is a foul for intentional grounding if a passer, facing an imminent loss of yardage because of pressure
from the defense, throws a forward pass without a realistic chance of completion. A realistic chance of completion is defined as a
pass that is thrown in the direction of and lands in the vicinity of an originally eligible offensive receiver.
.
.
Here is an exception to the rule (the other is being outside the pocket which does not apply here) but what happened on the play is the opposite of the rule's sequence. Dak was contacted first then started his throwing motion.
Item 2. Physical Contact. Intentional grounding should not be called if:
(a) the passer initiates his passing motion toward an eligible receiver and then is significantly affected by physical contact from a
defensive player that causes the pass to land in an area that is not in the direction and vicinity of an eligible receiver; or