Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Kotlin Everywhere
Search
Roberto Orgiu
July 20, 2018
Technology
78
0
Share
Kotlin Everywhere
Roberto Orgiu
July 20, 2018
More Decks by Roberto Orgiu
See All by Roberto Orgiu
Wellness & Droid
tiwiz
0
130
Behind the curtains
tiwiz
0
72
The Importance of Being Tested
tiwiz
0
430
An Android Dev start to Kotlin MPP
tiwiz
0
190
Fantastic API and where to find them
tiwiz
0
85
Flipping the Koin @ GDG Dev Party
tiwiz
1
78
Flipping the Koin
tiwiz
2
170
Trip into the async world @ NYC Kotlin Meetup
tiwiz
0
120
Trip into the async world
tiwiz
1
150
Other Decks in Technology
See All in Technology
はじめての MagicPod生成AI機能 機能紹介から活用方法まで
magicpod
0
120
Claude Code を安全に使おう勉強会 / Claude Code Security Basics
masahirokawahara
12
38k
Class.new is all you need
riseshia
1
200
Shipping AI Agents — Lessons from Production
vvatanabe
0
290
Google Cloud Next '26 の裏でこっそりリリースされたCloud Number Registry & Cloud Hub コスト分析 を試してみた
hikaru1001
0
120
Keeping Ruby Running on Cygwin
fd0
0
180
Arcana: Production-Ready RAG in Elixir @ ElixirConf EU 2026
georgeguimaraes
0
120
Microsoft 365 / Microsoft 365 Copilot : 自分の状態を確認する「ラベル」について
taichinakamura
0
380
AWS Transform CustomでIaCコードを自由自在に変換しよう
duelist2020jp
0
190
Choose your own adventure in agentic design patterns
glaforge
0
160
AI時代における技術的負債への取り組み
codenote
1
1.8k
20260428_Product Management Summit_tadokoroyoshiro
tadokoro_yoshiro
14
15k
Featured
See All Featured
Are puppies a ranking factor?
jonoalderson
1
3.3k
For a Future-Friendly Web
brad_frost
183
10k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
Information Architects: The Missing Link in Design Systems
soysaucechin
0
900
[RailsConf 2023] Rails as a piece of cake
palkan
59
6.5k
More Than Pixels: Becoming A User Experience Designer
marktimemedia
3
380
Visualization
eitanlees
150
17k
AI in Enterprises - Java and Open Source to the Rescue
ivargrimstad
0
1.2k
Become a Pro
speakerdeck
PRO
31
5.9k
Raft: Consensus for Rubyists
vanstee
141
7.4k
Why Our Code Smells
bkeepers
PRO
340
58k
How To Speak Unicorn (iThemes Webinar)
marktimemedia
1
440
Transcript
Kotlin everywhere
Who’s speaking Rob @ NYT Boris @ ClearScore 2
#CPIT2 sli.do Join the discussion
Where https://pusher.com/state-of-kotlin
Desktop apps with a little bit of Tornado™
• JavaFX • Beautiful DSL • UI + Background thread
• Injection • REST • Field validation • Can work™ with JS TornadoFX 6
tornadofx.io goo.gl/qSjBPG goo.gl/gcrZss
iOS apps and Android (but we wanted the WOW moment)
Kotlin Native COMMON no platform specific dependencies class/function declaration 9
PLATFORM implementations of platform-dependent declarations in the common module always an implementation of a single common module REGULAR targets specific platform can be dependency of platform modules can depend on platform modules
10
◇ common module defines expected declarations ◇ expected declarations never
contain any implementation code 11 expected
12 actual ◇ platform module provides actual declarations ◇ actual
declarations must match expected declarations
13 package org.jetbrains.foo expect class Foo(bar: String) { fun frob()
} fun main(args: Array<String>) { Foo("Hello").frob() }
14 package org.jetbrains.foo actual class Foo actual constructor(val bar: String)
{ actual fun frob() { println("Frobbing the $bar") } }
JVM Backend
16
Javascript Both Frontend and Backend!
18
19
◇ You can set and call everything you want on
properties of this type ◇ Disables compiler checks (beware of runtime errors) 20 dynamic
◇ Kotlin assumes the implementation is provided by the developer
(in JS) ◇ The compiler will not generate JS code for this function ◇ No auto completion 21 external
22 external fun require(module: String): dynamic fun main(args: Array<String>) {
val app = require(“express”) app.get(“/hello”, {req, res -> res.send(“Hello world!”) }) }
} 23 { Kotlin wrappers
24 @JsModule(“express”) external class Express { fun get( route: String,
callback: (req: Request, res: Response) -> Unit ) external class Request external class Response { fun send(data: String) } }
} 25 { Kotlin wrappers https://github.com/JetBrains/kotlin-wrappers
Thanks! Any questions? You can find us at: ◇ @_tiwiz
◇ @borisdamato 26