Question

Does anybody know any good examples of Dexterity-based Contenttypes, without use of Grok?

... just for learning purposes

Was it helpful?

Solution

Grok is kind of just a convenience wrapper around the ZCA. Your types can just be changed to use ZCML or just plain zope. For example, the following:

class View(grok.View):
    grok.context(IProgram)
    grok.require('zope2.View')

This would just convert to the following in ZCML:

<browser:page
    name="view"
    for="IProgram"
    permission="zope2.View"
    class=".yourviewmodule.View"
    template=".yourtemplate.pt"
    />
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top