View Full Version : Custom List Item

17 Feb 2012, 10:29 AM
Hi everyone,

How can I use a custom template for a list item in Sencha Designer? I'd like to create a container with buttons and such and then be able to use it in a List Item as the default template for each item in that list.


17 Feb 2012, 11:21 AM

Does List itemTpl config not serve your purpose?

17 Feb 2012, 11:41 AM
I guess it will do. I think I was overlooking the correct way of doing things... The way I intended to do it wouldn't work anyway, I see it now. I think I just figured how to do it using the itemTpl!


17 Feb 2012, 2:48 PM
To add some additional info: assuming you're building a Touch project, it sounds like you might be looking for the component-based DataView that is newly introduced in Touch 2: http://docs.sencha.com/touch/2-0/#!/guide/dataview-section-4 -- that would allow you to create a data view item by assembling components and have that set of components repeated for each item.

Unfortunately, we do not yet have support for creating component-based data view items in Designer -- we plan to support this soon however.

18 Feb 2012, 12:00 PM
Yes! That's what I was trying to do. But I guess I'll try to work around with the templates for now. If something goes wrong in the future and this kind of DataView customizations becomes really essential for my project then I'll hand code it myself :)

Thank you all for being so helpful!