Typing your password for every sudo gets old on a MacBook with a fingerprint sensor. Since macOS Sonoma there is a supported file for exactly this.
macOS ships a template at /etc/pam.d/sudo_local.template with one commented line. Copy it to sudo_local with that line switched on:
sed 's/^#auth/auth/' /etc/pam.d/sudo_local.template | sudo tee /etc/pam.d/sudo_local
The result should contain this line:
auth sufficient pam_tid.so
Open a new terminal and run sudo -v. A Touch ID prompt appears, and the password still works as a fallback.
The older trick was to edit /etc/pam.d/sudo directly, and every macOS update put it back. Apple added sudo_local so this setting survives updates, which is why I’d only use this file.
You are editing how sudo authenticates, so be careful. Use the command above exactly, keep a second terminal with a root shell open while you test, and don’t touch the other files in /etc/pam.d. Touch ID also doesn’t help in every situation. Over SSH there is no sensor to use, and inside tmux or screen the prompt usually doesn’t appear and sudo falls back to the password. With the lid closed and no Touch ID keyboard, the same happens.
Further reading: What's new for enterprise in macOS Sonoma (Apple Support)