$det A$
$\text{det}A$
$\mathrm{det}A$
$\operatorname{det}A$
Personally, I prefer the second or third option or fourth option, as without italicization, it distinguishes the "operator" from the operand (matrix $A$ in this case), and/or fm other variables, which are italicized.
And the advantage of the last option is the slight increase in spacing between the operator ($\operatorname{det}$) and the operand.
See Deven's suggestion in the comment below: if you plan to use the "operator" a lot in a given post, you can write a "preamble" defining a "new command", which helps economize the effort involved in formulating a long post.