Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Kotlin Blueprints

You're reading from   Kotlin Blueprints A practical guide to building industry-grade web, mobile, and desktop applications in Kotlin using frameworks such as Spring Boot and Node.js

Arrow left icon
Product type Paperback
Published in Dec 2017
Publisher Packt
ISBN-13 9781788390804
Length 260 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Authors (3):
Arrow left icon
Akshay Chordiya Akshay Chordiya
Author Profile Icon Akshay Chordiya
Akshay Chordiya
Ashish Belagali Ashish Belagali
Author Profile Icon Ashish Belagali
Ashish Belagali
Hardik Trivedi Hardik Trivedi
Author Profile Icon Hardik Trivedi
Hardik Trivedi
Arrow right icon
View More author details
Toc

Multiplatform Kotlin


A Kotlin multiplatform project allows you to compile the same code for multiple target platforms. Currently, supported target platforms are JVM and JS with Native, which is still under development and will be added later.

Note

Multiplatform Kotlin is still under review, similarly to Kotlin Native.

Project structure

A multiplatform project consists of three types of module—a common module, a platform module, and a regular module. Let's look at them in detail.

Common module

A common module contains platform-independent code, meaning it is not specific to any platform, as well as declarations without the implementation of platform-dependent APIs. Those declarations allow common code to depend on platform-specific implementations. This module is shared across other modules and is common between them, hence the name common. 

A common module can depend only on other common modules and libraries, including the kotlin-stdlib-common Kotlin standard library . 

A special metadata file...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image