[Grok-doc] Volunteering for a YUI tutorial

Jeroen Michiel jmichiel at yahoo.com
Tue Apr 13 10:42:17 EDT 2010


Hi Roger, 

1) Done

2) Well, by adding megrok.resource to the setup.py, everytime a Request object is created, it is of a class from hurry.zoperesource. The exact inner workings, I don't know either... a specific factory or adapter most likely.

3) Done.

Cheers



________________________________
From: Roger Erens <roger.erens at e-s-c.biz>
To: Jeroen Michiel <jmichiel at yahoo.com>
Cc: Sebastian Ware <sebastian at urbantalk.se>; grok-doc at zope.org
Sent: Tue, 13 April, 2010 11:26:08
Subject: Re: [Grok-doc] Volunteering for a YUI tutorial

Hi Jeroen,

On Tue, Apr 13, 2010 at 09:31, Jeroen Michiel <jmichiel at yahoo.com> wrote:
> Roger,
> Sorry for the immensely late reply!

No problem at all.

> 1) the yui-t7 class of the main div does this. it just is a header,
> content-area and footer, which is a very basic Grid, if it can be called a
> grid at all, indeed.

Ok, than it would be clearer to change this sentence
We created a basic layout with a link to a stylesheet, and a basic Grid.

to something a la:
We created a basic layout with a link to a stylesheet, and a basic
Grid by defining the main div-element to be of class :func:`yui-t7`

(I can incorporate the change if you want, but I noticed that you are
locking (thus editing?) the page)

> 2) megrok.resource is used implicitly in part 1. I explain this in the
> paragraph
> "Enter megrok.resource. This package uses hurry.zoperesource, which will
> override the default Request object with a special one that will add the
> needed resources to the <head> tag of your HTML just before rendering. Kind
> of magic..."

True, but can you say which module is using megrok.resource
implicitly? It's not clear from the code in layout.py nor app.py,
which are the only code files in part 1.

> 3) You may have a point there, but my reasoning was this: since we are using
> YUI grids for layouting, we might as well 'do it right' by using
> megrok.layout as well, as I figured this to be the most used use-case. The
> biggest problem I have with tutorials (in general) is that most only focus
> on the task at hand, and leave you clueless if the off-topic parts of the
> tutorial are quick-and-dirty implementations, or still best-practises. If
> you cut corners in a tutorial, you should state that, and point readers
> where to find info on doing it right. I decided to try and not cut any
> corners. There was no megrok.layout tutorial, so I decided to incorporate
> it, otherwise I would have referred to it.
> Maybe it makes this tutorial a bit 'heavy', indeed.
> The big picture of the tutorial was (more or less): explain how to do some
> typical YUI use-cases the Grok way: Reset/Grid, a menu, getting data
> asynchronously, sending data async, using JSON.
> Thanks for the remarks!

Maybe in the summary it could be mentioned that in this tutorial one
gets 4 for the price of 1:
it treats the usage of YUI, layout, navigation, and JSON in Grok.


Cheers,
Roger
> ----- Original Message ----
> From: Roger Erens <roger.erens at e-s-c.biz>
> To: Jeroen Michiel <jmichiel at yahoo.com>
> Cc: Sebastian Ware <sebastian at urbantalk.se>; grok-doc at zope.org
> Sent: Tue, 30 March, 2010 19:21:14
> Subject: Re: [Grok-doc] Volunteering for a YUI tutorial
>
> Hi Jeroen,
>
> Thanks for having solved the buidout issues. I've been busy editing
> (mainly formatting) your tutorial. I'm still not  yet clear about a
> few things in part 1; can you enlighten me?
>
> 1)
> Below the code for 'style.css' you mention that a basic Grid has been
> created. Is it? Only the class-value "yui-g" hints to that, but I
> wouldn't call that 'creating a basic grid'.
>
> 2)
> Then you mention megrok.resource, but this module is not used at all
> in part 1. Or is it? Maybe mentioning and explaining (which happens
> just above the 'app.py' code further down the page) it could be moved
> to part 3 where I see megrok.resource being used in code the first
> time.
>
> 3)
> Although I'm still missing the big picture of the tutorial, I'd like
> you to think about this:
> is the (megrok.)layout stuff not too distracting for this tutorial?
> Maybe it's worth a tutorial of its own; also simplifying the
> YUI-tutorial?
>
> Cheers,
>
> Roger
>
> On Mon, Mar 8, 2010 at 11:45, Jeroen Michiel <jmichiel at yahoo.com> wrote:
>> All typos are solved, and I'm looking into the buildout issues.
>>
>
>



      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.zope.org/pipermail/grok-doc/attachments/20100413/cae66a73/attachment-0001.html 


More information about the grok-doc mailing list