Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace configuration via Map objects with Kotlin DSL / method. #25

Open
smidf opened this issue Sep 20, 2020 · 0 comments
Open

Replace configuration via Map objects with Kotlin DSL / method. #25

smidf opened this issue Sep 20, 2020 · 0 comments
Labels
enhancement New feature or request

Comments

@smidf
Copy link
Contributor

smidf commented Sep 20, 2020

For example from:

setAdditionalProperties(
    mutableMapOf(
            "templateEngine" to "mustache",
            "dateLibrary" to "string"
            ...
    )
)

to: Kotlin DSL / configure blocks

additionalProperties {
    templateEngine = MUSTACHE // enum instead of string
    dateLibrary = STRING // enum instead of string
    generateInfrastructure = false
    ...
}

or to: Methods

additionalProperties {
    setTemplateEngine(MUSTACHE /* enum instead of string */)
    setDateLibrary(STRING /* enum instead of string */)
    generateInfrastructure(false)
    ...
}

This can eliminate setup errors, is much more descriptive and gives the user an overview of the options offered.

@smidf smidf added the enhancement New feature or request label Sep 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant