[Seaside] still struggling with the confusing scripting API's
asqueaker at gmail.com
Sat Oct 31 16:04:18 UTC 2015
I wasn't sure, good to know.
> I believe it was never intended to cover the complete language either. We can, of course, always extend the possibilities.
True, but I am attracted to the idea of generating it via Smalltalk
messages because (1) I think that approach provides me easier
opportunities for factoring and reuse, plus (2) I don't end up with
"two languages", each with their own syntax, in one method, which
becomes VERY difficult to read and maintain because I can't use my
IDE's capability to "select expressions" inside (parens), [brackets],
> I would definitely opt for this version:
One of my reservations about that is it bypasses the brush API, which
is not only the prescribed way to use Seaside, it also sets up some
state on the Canvas ('currentBrush') which might be needed..?
So, can I do that going through the Brush api? Everything I try
causes the various HTML characters to be escaped...
> Alternatively, the following is possible by adding a simple convenience method:
> With JSObject>>create:withArguments: implemented as:
> create: anObject withArguments: aCollection
> "new <anObject>(<aCollection>)"
> ^ (anObject apply: aCollection) create
I think I like that..
> Depending on your use case, the other options are:
> Hope this helps
More information about the seaside