This Django ticket says that they will not add a default Django template file extension. What file extension do you use?
+4
A:
For HTML pages: .html
For XML data (RSS and such): .xml
Etc
Just because they're templates doesn't mean they should have some sort of special extension.
As mentioned in the ticket:
- You already know the files are templates because they should be in a template directory
- You don't want to have to open up files to see what they are (HTML, CSS, XML, etc). You would have to do this with a generic extension like .djt.
- Most editors get this right with the proper filetype extension anyways so there is little reason to change this convention.
- However, something like .djt could allow for Django specific icons and syntax types.
Nick Presta
2010-01-09 23:28:13
+1 except for maybe #4. There's no need for new magic here. Vim and Notepad++ already know about Django template tag highlighting so it may not even be necessary for a `.djt` extension. This ain't Rocket Surgery.
Peter Rowell
2010-01-10 04:12:19
+4
A:
Ruby on Rails uses .erb.html
for html erb templates, something similar will work for django too.
adamse
2010-01-09 23:35:02
A:
I use the same name I would use for this file, if it wasn't a template. Thanks to this, I instantly know, what to expect inside. And for me every file that is being served is through views is a template, it sometimes just isn't filled with anything or even doesn't use markup language.
gruszczy
2010-01-09 23:59:45