On Dec 31 2008, 12:05 am, buda <www...@pochta.ru> wrote:
> But to store metadata in objects - is doing overjob - elements might
> be added or deleted or changed their style or state - and syncronyze
> elmenets state with their object mappers - is very hard and
> useless!!!!

It's not hard at all, and definitely not useless (after all, you want
to do it).

Consider that DOM elements are simply one way of displaying the data
in business objects.   Do all of your work with the objects, then send
the data to the screen to be viewed.  That model separates the
business logic from the display logic.

Of course there are some functions that are pure UI (e.g. sorting a
table or list) but others, like updating the table rows from a server,
should be done with an object, then written to the UI.

If you only have one table representing a single data object, it
probably doesn't matter if you just update the table directly using
AJAX or similar, but once you have a number of data objects and maybe
a number of different ways of displaying their content, you will want
to separate display from business logic.

--
Rob.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to