Changing .txt to other file formats
I am a coder, and I wanted to use TextEdit to edit my code, but every time I need to change the format (for example changing name.txt to newname.json, newname.py, etc.), it always adds a .txt at the end, which annoys me. I went into the preferences and help pages and cannot find a solution. How do I change the file format?
MacBook Pro