I would like to ask for directions or a tutorial on how to properly create and integrate a custom gwt widget.
What is the proper way in creating of creating a custom widget?
Should I create a separate project using the GWT sdk
OR
should I just use Vaadin’s way of creating a custom component?
I also tried to follow the integration of an existing gwt component from: https://vaadin.com/wiki/-/wiki/Main/Integrating%20an%20existing%20GWT%20widget
Where you have to download a jar from gwt g-flot and put it in the projects web-inf folder.
And the problem is, in my Maven setup, there is no web-inf folder, since the libraries are acquired through the pom and will be automatically packaged with the project instead of putting it manually.
Okay, so what I will do is add this as a separate module in a multi-module maven project? And then just add it as a dependency for my Vaadin Project?
Is that right?
You might want to create a separate projects eventually (one for demo / development that’s not included in release and one for the widget only), but yeah.
Yep
I did try to include it in the .gwt.xml file.
The error doesn’t occur on the project module of the addon itself, it occurs in the project where I add the addon as a dependency too.
EDIT:
There’s an error when I’m trying to compile the widgetset too in the addon, its this:
GWT Module com.allen-sauer.gwt.dnd not found in project sources or resources.
I have the dependency in my pom.xml:
One idea: try adding another copy of the dependency with
<classifier>sources</classifier>
as GWT compilation requires also the source code of the client side modules to be available, and not all add-ons include it in the main JAR.
And on the pom of the project, its:
<dependency>
<groupId>com.allen-sauer.gwt.dnd</groupId>
<artifactId>gwt-dnd</artifactId>
<version>3.3.4</version>
</dependency>
<dependency>
<groupId>com.allen-sauer.gwt.dnd</groupId>
<artifactId>gwt-dnd</artifactId>
<version>3.3.4</version>
<classifier>sources</classifier>
</dependency>
I placed two dependencies, one with the classifier, still a no go.