• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

nfrankel/kaadin: Kotlin DSL for Vaadin

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称(OpenSource Name):

nfrankel/kaadin

开源软件地址(OpenSource Url):

https://github.com/nfrankel/kaadin

开源编程语言(OpenSource Language):

Kotlin 99.5%

开源软件介绍(OpenSource Introduction):

Kaadin

Build Status Code coverage download

Kaadin is a library to create Vaadin Graphical User Interface using a Kotlin Domain-Specific Language .

1. Two-minutes tutorial

An example is worth a thousand words:

import ch.frankel.kaadin.* //(1)
import com.vaadin.server.*
import com.vaadin.ui.*

class FirstStepUI(): UI() {
    override fun init(request: VaadinRequest) {
        verticalLayout(margin = true, spacing = true) { //(2)
            label("Welcome to Vaadin") //(3)
        }
    }
}
  1. Import the namespace ch.frankel.kaadin.*

    1. There’s one Kaadin function for each Vaadin component e.g. button() maps Button()

  2. The topmost component will automatically be added as the UI content. There’s one such function per common Vaadin component.

  3. Nested blocks allow to add children components and configure them

2. Usage

  1. Build

    mvn install
  2. Use

    <dependency>
        <groupId>ch.frankel.kaadin</groupId>
        <artifactId>kaadin-core</artifactId>
        <version>0.1-SNAPSHOT</version>
    </dependency>

3. Going further

The full documentation is available on the Kaadin site.

4. License

Kaadin is distributed under the friendly Apache 2.0 License.




鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
vert-x3/vertx-examples: Vert.x examples发布时间:2022-07-10
下一篇:
ajalt/mordant: Multiplatform text styling for Kotlin command-line applications发布时间:2022-07-10
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap