Pregunta

I am new in GWT. Is this possible to create multiple HTML pages in GWT? and if can create, than it is relevant to create page?

¿Fue útil?

Solución

If you find any html page in gwt, you will find two entries which is common to all html page of gwt.

That is below.

<script type="text/javascript" language="javascript" src="{modulename}/{modulename}.nocache.js"></script>

 <body>
    <iframe src="javascript:''" id="__gwt_historyFrame" tabIndex='-1' style="position:absolute;width:0;height:0;border:0"></iframe>
 </body>

It loads module.cache.js into iframe.

So In short gwt work on one page only. it is single page application.

Refer: how you can do multipage in gwt?

Otros consejos

If your objective is to have multiple page patterns for the same GWT application, you can create multiple pages, GWT won't prevent you from doing that (it doesn't even know it is called from different HTML pages).

So technically it is possible, now it is said, I won't recommend you doing that. You'd rather do different css files and swap between them. It will be easier to maintain your app.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top