--- title: Creating a Project in IntelliJ order: 120 layout: page --- [[getting-started.idea]] = Creating a Project with IntelliJ IDEA With both Community Edition and Ultimate Edition, you can create a Vaadin application most easily with a Maven archetype and deploy it to a server with a Maven run/debug configuration. [[getting-started.idea.maven]] == Creating a Maven Project You can choose to create a Maven project in IntelliJ IDEA. You will not have the application server integration, but can deploy the application to an application server using a run/debug configuration. . Select [menuchoice]#New Project# . In the [guilabel]#New Project# window, select [menuchoice]#Maven# //<?dbfo-need height="8cm" ?> . Select the Java SDK to be used for the project. Vaadin requires at least Java 8. . Check [guilabel]#Create from archetype# checkbox . If the Vaadin archetype is not in the list, click [guibutton]#Add archetype#, enter [guilabel]#GroupId# [literal]#++com.vaadin++#, [guilabel]#ArtifactId# [literal]#++vaadin-archetype-application++#, and [guilabel]#Version# [literal]#++LATEST++# (or a specific version number). + Click [guibutton]#OK# in the dialog. //<?dbfo-need height="8cm" ?> . Select the archetype + image::img/idea-maven-newproject-1.png[scaledwidth=100%] + Click [guibutton]#Next#. //<?dbfo-need height="6cm" ?> . Give a Maven [guilabel]#GroupID#, [guilabel]#ArtifactID#, and a [guilabel]#Version# for the project, or use the defaults. . Review the general Maven settings and settings for the new project. You may need to override the settings, especially if you are creating a Maven project for the first time. . Finish the wizard. //<?dbfo-need height="8cm" ?> Creating the Maven project takes some time as Maven fetches the dependencies. Once done, the project is created and the Maven POM is opened in the editor. Fort more detailed instructions, refer to https://www.jetbrains.com/help/idea/ [[getting-started.idea.maven.compiling]] === Compiling the Project To compile a Vaadin application using Maven, you can define a run/debug configuration to execute a goal such as [literal]#++package++# to build the deployable WAR package. It will also compile the widget set and theme, if necessary. See <> for more details. Compilation is included in the following instructions for deploying the application. [[getting-started.idea.maven.deploying]] === Deploying to a Server There exists Maven plugins for deploying to various application servers. For example, to deploy to Apache Tomcat, you can to configure the [literal]#++tomcat-maven-plugin++# and then execute the [literal]#++tomcat:deploy++# goal. See the documentation of the plugin that you use for more details. If no Maven plugin exists for a particular server, you can always use some lower-level method to deploy the application, such as running an Ant task. In the following, we create a run/debug configuration to build, deploy, and launch a Vaadin Maven application on the light-weight Jetty web server. . Select "Run > Edit Configurations". . Click [guibutton]#+# and select [guilabel]#Maven# to create a new Maven run/debug configuration. . Enter a [guilabel]#Name# for the run configuration. For the [guilabel]#Command line#, enter `package jetty:run` to first compile and package the project, and then launch Jetty to run it. + Click [guibutton]#OK#. . Select the run configuration in the toolbar and click the [guibutton]#Run# button beside it. Compiling the project takes some time on the first time, as it compiles the widget set and theme. Once the run console pane informs that Jetty Server has been started, you can open the browser at the default URL http://localhost:8080/. >feature/bootstrap-annotation Vaadin 6, 7, 8 is a Java framework for modern Java web applications: https://github.com/vaadin/frameworkwww-data
aboutsummaryrefslogtreecommitdiffstats
path: root/server/src/main/java/com/vaadin/ui/Panel.java
blob: 7b1333d89810c07f7df4401b4889e742b6d470ed (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354