Re: AbstractTransformerBehavior prevents further rendering.

2020-08-17 Thread Sven Meier

Hi Thorsten,

please create a quickstart, without debugging I cannot pinpoint the problem.

Have fun
Sven


On 17.08.20 19:52, Thorsten Schöning wrote:

Hi all,

I'm using Wicket as a renderer for HTML-reports WITHOUT browser, web
server or requests, only by using ComponentRenderer. There are two
implementations of AbstractTransformerBehavior to update "colspan"
attributes of table cells and IDs of arbitrary HTML nodes. Both are
used on the same component:


resultsCont.add(new DvResultsCont.ColSpanUpdater());
resultsCont.add(new MkIdReplacer
(
   "th", "id", "td", "headers",
   String.format("%d.%s", itemIdx, kindOfDetail)
));

When only ONE of both behaviours is used, the page renders
successfully and it doesn't make any difference which one is used. If
both of those are used OTOH, the page stops rendering after the markup
of the component "resultsCont". That component renders to a table, so
the last markup I have is the following:



[...]


In theory, after that table there should be additional content like
foots, closing elements for HTML itself etc. So the current rendering
is invalid. It's important to note, though, that I don't get any
exception, things seems to simply stop. When enabling DEBUG logging
during rendering, the logs make pretty much clear that Wicket really
tries to continue rendering, but the output is simply missing.

It might be of interest that the resulting HTML is somewhat large,
around 1,7 MiB. Though I didn't find any hard-coded limits in the
behaviours yet in that direction.

As no exceptions are thrown and output seems to simply be ignored at
some point, I have the feeling the problem is in handling the response
objects in "AbstractTransformerBehavior.afterRender". But I couldn't
find anything problematic during debugging yet and things seem to work
with only one behaviour applied.

Do you have any idea what might go wrong? Is there any size limit with
behaviours or when rendering at all? Is it generally OK to place
multiple behaviours onto one and the same component?

Thanks for your ideas!

Mit freundlichen Grüßen,

Thorsten Schöning



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



AbstractTransformerBehavior prevents further rendering.

2020-08-17 Thread Thorsten Schöning
Hi all,

I'm using Wicket as a renderer for HTML-reports WITHOUT browser, web
server or requests, only by using ComponentRenderer. There are two
implementations of AbstractTransformerBehavior to update "colspan"
attributes of table cells and IDs of arbitrary HTML nodes. Both are
used on the same component:

> resultsCont.add(new DvResultsCont.ColSpanUpdater());
> resultsCont.add(new MkIdReplacer
> (
>   "th", "id", "td", "headers",
>   String.format("%d.%s", itemIdx, kindOfDetail)
> ));

When only ONE of both behaviours is used, the page renders
successfully and it doesn't make any difference which one is used. If
both of those are used OTOH, the page stops rendering after the markup
of the component "resultsCont". That component renders to a table, so
the last markup I have is the following:

> 
> [...]
> 

In theory, after that table there should be additional content like
foots, closing elements for HTML itself etc. So the current rendering
is invalid. It's important to note, though, that I don't get any
exception, things seems to simply stop. When enabling DEBUG logging
during rendering, the logs make pretty much clear that Wicket really
tries to continue rendering, but the output is simply missing.

It might be of interest that the resulting HTML is somewhat large,
around 1,7 MiB. Though I didn't find any hard-coded limits in the
behaviours yet in that direction.

As no exceptions are thrown and output seems to simply be ignored at
some point, I have the feeling the problem is in handling the response
objects in "AbstractTransformerBehavior.afterRender". But I couldn't
find anything problematic during debugging yet and things seem to work
with only one behaviour applied.

Do you have any idea what might go wrong? Is there any size limit with
behaviours or when rendering at all? Is it generally OK to place
multiple behaviours onto one and the same component?

Thanks for your ideas!

Mit freundlichen Grüßen,

Thorsten Schöning

-- 
Thorsten Schöning   E-Mail: thorsten.schoen...@am-soft.de
AM-SoFT IT-Systeme  http://www.AM-SoFT.de/

Telefon...05151-  9468- 55
Fax...05151-  9468- 88
Mobil..0178-8 9468- 04

AM-SoFT GmbH IT-Systeme, Brandenburger Str. 7c, 31789 Hameln
AG Hannover HRB 207 694 - Geschäftsführer: Andreas Muchow


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket and Vue.js synergy

2020-08-17 Thread Илья Нарыжный
Dear, Wicket Developers,

There is actually one issue in Wicket which will be good to get fixed
before next release:
https://issues.apache.org/jira/projects/WICKET/issues/WICKET-6815
Without it, we have to use a brutal workaround:
https://github.com/OrienteerBAP/vuecket/blob/master/vuecket/src/main/java/org/orienteer/vuecket/util/FixWICKET6815.java

This issue is about the parsing of non-standard HTML attributes which
apparantly used by VueJS: v-bind:attr, @attr, :attr. Hopefully, the
fix of this issue will be helpful for better integration of Wicket
with other JS frameworks as well.

Ilya
-
Orienteer(http://orienteer.org) - open-source Business Application Platform

On Sun, Aug 16, 2020 at 2:55 PM Илья Нарыжный  wrote:
>
> Hello, Wicket Users!
>
> Vuecket went through an important milestone: all required
> functionality is ready to be used.
> Also here is tutorial on how to use Vuecket:
> https://medium.com/orienteer/vuejs-wicket-vuecket-ee7bd5534fee
>
> P.S. Btw, will really appreciate it if the link to Vuecket can be
> added wicket.apache.org.
> P.P.S There is also a curated list of Wicket related projects which
> will be also good to have on the official Wicket site:
> https://github.com/PhantomYdn/awesome-wicket If not all of these
> projects, but at least most of them:)
>
> Thanks,
> Ilya
> -
> Orienteer(http://orienteer.org) - open source Business Application Platform
>
> On Tue, Aug 11, 2020 at 12:44 AM Илья Нарыжный  wrote:
> >
> > Hello,
> >
> > Made big progress on marrying Wicket and Vue.
> > Currently, existing features are listed in README:
> > https://github.com/OrienteerBAP/vuecket/blob/master/README.md
> > Will really appreciate constructive feedback! (Even if it's something
> > like "I didn't understand the README":) )
> >
> > Thanks,
> > Ilya
> > -
> > Orienteer(http://orienteer.org) - open source Business Application Platform
> >
> >
> > On Tue, Aug 4, 2020 at 12:59 AM Илья Нарыжный  wrote:
> > >
> > > Thank you, Martin!
> > >
> > > If somebody interested, work has begun in the following repository:
> > > https://github.com/OrienteerBAP/vuecket
> > > Features which I plan to add soon:
> > >
> > > 1) Support of Data Channel: channels for synchronization of data on
> > > Vue side and named Models on wicket side. 1 way sync, 2 way sync, one
> > > time, runtime, websocket.
> > > 2) Support of subscriptions to vue events.
> > > 3) Support of storing Vue code as Json (plain String is Java), *.vue
> > > files, reference to NPM package
> > >
> > > Btw, recently we released JNPM (https://github.com/OrienteerBAP/JNPM)
> > > - native java API for work with NPM. Idea is to use JNPM for more
> > > fluent and runtime integration with NPM registry and NPM packages. For
> > > example, to allow quickly link wicket component to the corresponding
> > > implementation in NPM package, add data channels and event listeners.
> > > Ideally with minimal "wrapping" JS code.
> > > Ultimate goal is to make our product (Orienteer) even more rapid for
> > > applications development due to reinforcement of front-end support.
> > >
> > > Thanks,
> > > Ilya
> > > -
> > > Orienteer(http://orienteer.org) - open source Business Application 
> > > Platform
> > >
> > > On Fri, May 8, 2020 at 6:18 AM Martin Grigorov  
> > > wrote:
> > > >
> > > > Hi Илья,
> > > >
> > > > 7 years ago I've made a (small) integration with Ractive.js:
> > > > https://github.com/martin-g/wicket-ractive and blogged about it
> > > > https://wicketinaction.com/2013/08/surgical-ajax-updates-with-ractive-js/
> > > > IMO Vue.js has started as a fork from Ractive.js but Rich Harris says it
> > > > just influenced it: 
> > > > https://twitter.com/mtgrigorov/status/806531052743311360
> > > >  :-)
> > > > I like them both a lot!
> > > > You can use wicket-ractive as an inspiration! It just uses Ractive.js 
> > > > for
> > > > the Ajax updates (instead of Wicket's XML approach). I didn't go any
> > > > deeper, like integrating on component level
> > > >
> > > > Have fun!
> > > >
> > > > On Thu, May 7, 2020 at 6:40 AM Илья Нарыжный  wrote:
> > > >
> > > > > Hello,
> > > > >
> > > > > I code on Wicket for around 10 years and on Vue JS for a few months
> > > > > and found a lot of in common between these frameworks. There are 100
> > > > > and 1 ways in Wicket how to integrate a front-end framework. But with
> > > > > pre-created Wicket library - integration might be even deeper and lead
> > > > > to a synergy effect.
> > > > >
> > > > > I've started to collect some ideas and "design notes" about the
> > > > > library which allows integrating Wicket and Vue on another level. I
> > > > > will really appreciate any feedback and more ideas and comments. Here
> > > > > is this document:
> > > > >
> > > > >