Wiiboy (jordon...@gmail.com) wrote:
> Hi guys,
> I'm thinking about making multiple views files.  I'm just wondering
> whether:
> a. There's any problems with that
> b. many people do it.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

Hi wiiboy,

You mean having more than one module for your views?

> a. There's any problems with that
Since it's all Python I don't think there should be any problems with
that.

I would probably have an app tree structure like this:

test_app/
|-- __init__.py
|-- models.py
|-- tests.py
|-- view
|   |-- __init__.py
|   |-- blog_form_view.py
|   `-- blog_view.py
`-- views.py

Where my views.py simply imports the views in the ``view`` folder. 
I think it's essential that you keep the views.py, when you're not
running a personalized fork of Django and writing reusable apps. ;)

> b. many people do it.
AFAIK I don't know many Django developers who do that (if any). But why
not do it?

Large views modules can be quite readable and browseable if your
editor supports intelligent code folding.

Correct me if I got something wrong.

Cheers,
Kenny

-- 
  Kenny Meyer
  Software Geek | http://kenny.alwaysdata.net

  Shoot for the moon, even if you miss, you'll land amongst the stars..
    - Les Brown

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to