Configuration
Customizing the configuration of a Hilla application for both the development environment and for execution.
Enable multi-module projects and other JVM languages
Tip
|
Preview features
Support for multi-module projects and all JVM languages are preview features.
You need to enable the hillaEngine feature flag to use them.
|
To allow the endpoint generator to use the correct parameter names when building TypeScript files, you need to configure the Java compiler to not omit them by using the javac -parameters
option. For example, the following shows how configure the Maven plugin to include that compiler option:
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.10.1</version>
<configuration>
<encoding>UTF-8</encoding>
<!-- tag::snippet[] -->
<parameters>true</parameters>
<!-- end::snippet[] -->
</configuration>
</plugin>
</plugins>
</build>
See each programming languageās documentation how to enable the parameters
option:
TypeScript compiler options
The TypeScript compiler requires a tsconfig.json
file.
If there is no tsconfig.json
in the project root, the vaadin-maven-plugin
generates one.
The default configuration looks similar to the following:
{
"compilerOptions": {
"sourceMap": true,
"inlineSources": true,
"module": "esNext",
"target": "es2017",
"moduleResolution": "node",
"strict": true,
"noFallthroughCasesInSwitch": true,
"noImplicitReturns": true,
"noImplicitAny": true,
"noImplicitThis": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"experimentalDecorators": true,
"baseUrl": "frontend",
"paths": {
"Frontend/*": [
"*"
]
}
},
"include": [
"frontend/**/*.ts",
"frontend/index.js",
"types.d.ts"
],
"exclude": []
}