According to https://prettier.io/docs/en/options.html#end-of-line the 'lf' value is already the default in current versions of prettier.
Other tools might be changing the end of lines too. How are you validating the where the change happens?
While investigating my own question about line endings, I saw a claim that many recent code editors support either format. In the past I'd use Notepad++ to both see what format a file is in, and not worry which format since it could adapt itself. There is a status area at the bottom that'll say which type of line ending the file has, and the editor can translate or match whichever type you need (might need a plugin, it's been a while since I needed that).
As another likely source I'd investigate your git configurations, as it can work some magic there. I believe the default is to use Linux/Mac format for text files in the repo, but will translate those to the local expected format on checkout (and reverse that for commits from a Windows box).
https://docs.github.com/en/get-started/getting-started-with-git/configuring-git-to-handle-line-endings
That page mentions .gitattributes
and how to tell git what file types to alter and which to keep the same. I'll copy their example since it explains what they're doing and why. There is a lot more explanation on that page though.
# Set the default behavior, in case people don't have core.autocrlf set.
* text=auto
# Explicitly declare text files you want to always be normalized and converted
# to native line endings on checkout.
*.c text
*.h text
# Declare files that will always have CRLF line endings on checkout.
*.sln text eol=crlf
# Denote all files that are truly binary and should not be modified.
*.png binary
*.jpg binary
* text eol=lf
– Cropland