Skip to content

Commit a3fdb73

Browse files
committed
Migrate Vaadin Demo to v25
1 parent c086ece commit a3fdb73

3 files changed

Lines changed: 41 additions & 49 deletions

File tree

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# Delay install of newly released packages to prevent supply chain attacks
2+
minimumReleaseAge: 180 # 3h
3+
overrides:
4+
# Remove unused packages
5+
# glob CLI unused
6+
"jackspeak": "npm:empty-npm-package@1.0.0"
7+
"foreground-child": "npm:empty-npm-package@1.0.0"
8+
"package-json-from-dist": "npm:empty-npm-package@1.0.0"
9+
# rollup-plugin-visualizer CLI unused
10+
"yargs": "npm:empty-npm-package@1.0.0"
11+
"open": "npm:empty-npm-package@1.0.0"
12+
# transform-ast test only
13+
"nanobench": "npm:empty-npm-package@1.0.0"
14+
# Workbox unused
15+
"workbox-google-analytics": "npm:empty-npm-package@1.0.0"
16+
"@surma/rollup-plugin-off-main-thread": "npm:empty-npm-package@1.0.0"
17+
"@babel/preset-env": "npm:empty-npm-package@1.0.0"
18+
"@babel/runtime": "npm:empty-npm-package@1.0.0"
19+
"@rollup/plugin-replace@2.4.2": "npm:empty-npm-package@1.0.0"
20+
"@rollup/plugin-babel": "npm:empty-npm-package@1.0.0"
21+
"@rollup/plugin-node-resolve": "npm:empty-npm-package@1.0.0"
22+
"@rollup/plugin-terser": "npm:empty-npm-package@1.0.0"
23+
"tempy": "npm:empty-npm-package@1.0.0"
24+
# Disable telemetry
25+
"@vaadin/vaadin-usage-statistics": "npm:empty-npm-package@1.0.0"

demo/webapp-vaadin/pom.xml

Lines changed: 13 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -28,45 +28,11 @@
2828
<groupId>com.vaadin</groupId>
2929
<artifactId>vaadin-spring-boot-starter</artifactId>
3030
<exclusions>
31-
<!-- We don't use hilla, so we don't need it -->
32-
<exclusion>
33-
<groupId>com.vaadin</groupId>
34-
<artifactId>hilla</artifactId>
35-
</exclusion>
36-
<exclusion>
37-
<groupId>com.vaadin</groupId>
38-
<artifactId>hilla-dev</artifactId>
39-
</exclusion>
40-
<!-- https://github.com/vaadin/copilot/issues/7 -->
41-
<exclusion>
42-
<groupId>com.vaadin</groupId>
43-
<artifactId>copilot</artifactId>
44-
</exclusion>
45-
<!-- We use Lumo - also not sure why this is included by default -->
46-
<exclusion>
47-
<groupId>com.vaadin</groupId>
48-
<artifactId>vaadin-material-theme</artifactId>
49-
</exclusion>
50-
<!-- React is not enabled and thus not required -->
51-
<exclusion>
52-
<groupId>com.vaadin</groupId>
53-
<artifactId>flow-react</artifactId>
54-
</exclusion>
55-
<!-- Is not active (requires license - just an OpenAI wrapper), why is this shipped by default (dev-only)? -->
56-
<exclusion>
57-
<groupId>com.vaadin</groupId>
58-
<artifactId>ui-tests</artifactId>
59-
</exclusion>
6031
<!-- There is like 10 people on the planet that need this, why is this shipped by default??? -->
6132
<exclusion>
6233
<groupId>com.vaadin</groupId>
6334
<artifactId>collaboration-engine</artifactId>
6435
</exclusion>
65-
<!-- Just useless for us - we don't use an appserver -->
66-
<exclusion>
67-
<groupId>com.vaadin.servletdetector</groupId>
68-
<artifactId>throw-if-servlet3</artifactId>
69-
</exclusion>
7036

7137
<!-- We don't use these components -->
7238
<exclusion>
@@ -91,6 +57,17 @@
9157
</exclusion>
9258
</exclusions>
9359
</dependency>
60+
<dependency>
61+
<groupId>com.vaadin</groupId>
62+
<artifactId>vaadin-dev</artifactId>
63+
<optional>true</optional>
64+
<exclusions>
65+
<exclusion>
66+
<groupId>com.vaadin</groupId>
67+
<artifactId>copilot</artifactId>
68+
</exclusion>
69+
</exclusions>
70+
</dependency>
9471

9572
<!-- SSE -->
9673
<dependency>
@@ -170,11 +147,11 @@
170147
</execution>
171148
</executions>
172149
<configuration>
150+
<!-- Allows for greater control -->
151+
<pnpmEnable>true</pnpmEnable>
173152
<!-- Can only be true if hilla is used -->
174153
<!-- Takes a few seconds to scan everything for hilla -->
175154
<frontendHotdeploy>false</frontendHotdeploy>
176-
<!-- Prevent scanning for react (not used) -->
177-
<reactEnable>false</reactEnable>
178155
<frontendScanner>
179156
<includes>
180157
<include>
@@ -225,19 +202,6 @@
225202
</profile>
226203
<profile>
227204
<id>prod</id>
228-
<dependencies>
229-
<!-- Exclude development dependencies from production -->
230-
<dependency>
231-
<groupId>com.vaadin</groupId>
232-
<artifactId>vaadin-core</artifactId>
233-
<exclusions>
234-
<exclusion>
235-
<groupId>com.vaadin</groupId>
236-
<artifactId>vaadin-dev</artifactId>
237-
</exclusion>
238-
</exclusions>
239-
</dependency>
240-
</dependencies>
241205
<build>
242206
<resources>
243207
<resource>

demo/webapp-vaadin/src/main/java/software/xdev/sse/demo/Application.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,17 @@
1010
import org.springframework.scheduling.annotation.EnableAsync;
1111
import org.springframework.scheduling.annotation.EnableScheduling;
1212

13+
import com.vaadin.flow.component.dependency.StyleSheet;
1314
import com.vaadin.flow.spring.annotation.EnableVaadin;
15+
import com.vaadin.flow.theme.lumo.Lumo;
1416

1517

1618
@SuppressWarnings({"checkstyle:HideUtilityClassConstructor", "PMD.UseUtilityClass"})
1719
@SpringBootApplication(exclude = {ErrorMvcAutoConfiguration.class})
1820
@EnableScheduling
1921
@EnableAsync
2022
@EnableVaadin("software.xdev.sse.demo.ui")
23+
@StyleSheet(Lumo.STYLESHEET)
2124
public class Application
2225
{
2326
@SuppressWarnings("PMD.AvoidSystemSetterCall")

0 commit comments

Comments
 (0)