Opened 17 years ago
Closed 13 years ago
#7281 closed New feature (wontfix)
Add doctype tag to webdesign template tags
| Reported by: | Owned by: | nobody | |
|---|---|---|---|
| Component: | contrib.webdesign | Version: | dev | 
| Severity: | Normal | Keywords: | webdesign | 
| Cc: | d1fffuz0r@… | Triage Stage: | Accepted | 
| Has patch: | yes | Needs documentation: | no | 
| Needs tests: | no | Patch needs improvement: | no | 
| Easy pickings: | no | UI/UX: | no | 
Description
This was very lightly discussed here in the context of creating tags for newforms.  I extracted the idea of doctypes and included it in the contrib.webdesign template tag library.
Attachments (2)
Change History (14)
by , 17 years ago
| Attachment: | webdesign.diff added | 
|---|
comment:1 by , 17 years ago
comment:2 by , 17 years ago
| milestone: | → post-1.0 | 
|---|---|
| Triage Stage: | Unreviewed → Accepted | 
comment:3 by , 17 years ago
More work on this: http://code.google.com/p/django-html/
See also http://groups.google.com/group/django-developers/browse_thread/thread/f04aed2bc60274f0
I think these should be in the defaulttags rather than sitting in contrib, as the ability to write tags that are doctype aware feels like it should be a core promise of Django's API.
comment:5 by , 15 years ago
| Component: | Contrib apps → contrib.webdesign | 
|---|
comment:6 by , 15 years ago
| Severity: | → Normal | 
|---|---|
| Type: | → New feature | 
comment:7 by , 15 years ago
| Easy pickings: | unset | 
|---|---|
| Needs tests: | set | 
by , 13 years ago
| Attachment: | ticket_7281.patch added | 
|---|
Improvements. Tag moved to builtins, tests and documentation.
comment:10 by , 13 years ago
| Needs tests: | unset | 
|---|
comment:11 by , 13 years ago
This ticket was opened 5 years ago. Since then HTML5 has won the HTML/XHTML race and it solves the doctype problem by simplifying it drastically: <!DOCTYPE HTML>.
In my opinion the {% doctype %} tag would add very little value nowadays:
- existing projects already have doctypes hardcoded in their templates and don't need it;
 - new projects should use HTML5 in general — it's an established best practice since 2010 (roughly).
 
I'm leaning towards "wontfix". I'm sorry, because you've obviously put some effort into the patch (it looks good). When you're working on such an old ticket, it's often a good idea to make sure the decision still stands, especially if it depends on the current state of the ecosystem — that states changes over the course of years.
comment:12 by , 13 years ago
| Resolution: | → wontfix | 
|---|---|
| Status: | new → closed | 
I got a second vote for "wontfix" on IRC.
Forgot the link to the Django-devs list post by Simon Willison: http://groups.google.com/group/django-developers/msg/00a5d83e8c80df6c