https://kotlinlang.org logo
Join the conversationJoin Slack
Channels
100daysofcode
100daysofkotlin
100daysofkotlin-2021
advent-of-code
aem
ai
alexa
algeria
algolialibraries
amsterdam
android
android-architecture
android-databinding
android-studio
androidgithubprojects
androidthings
androidx
androidx-xprocessing
anime
anko
announcements
apollo-kotlin
appintro
arabic
argentina
arkenv
arksemdevteam
armenia
arrow
arrow-contributors
arrow-meta
ass
atlanta
atm17
atrium
austin
australia
austria
awesome-kotlin
ballast
bangladesh
barcelona
bayarea
bazel
beepiz-libraries
belgium
berlin
big-data
books
boston
brazil
brikk
budapest
build
build-tools
bulgaria
bydgoszcz
cambodia
canada
carrat
carrat-dev
carrat-feed
chicago
chile
china
chucker
cincinnati-user-group
cli
clikt
cloudfoundry
cn
cobalt
code-coverage
codeforces
codemash-precompiler
codereview
codingame
codingconventions
coimbatore
collaborations
colombia
colorado
communities
competitive-programming
competitivecoding
compiler
compose
compose-android
compose-desktop
compose-hiring
compose-ios
compose-mp
compose-ui-showcase
compose-wear
compose-web
connect-audit-events
corda
cork
coroutines
couchbase
coursera
croatia
cryptography
cscenter-course-2016
cucumber-bdd
cyprus
czech
dagger
data2viz
databinding
datascience
dckotlin
debugging
decompose
decouple
denmark
deprecated
detekt
detekt-hint
dev-core
dfw
docs-revamped
dokka
domain-driven-design
doodle
dsl
dublin
dutch
eap
eclipse
ecuador
edinburgh
education
effective-kotlin
effectivekotlin
emacs
embedded-kotlin
estatik
event21-community-content
events
exposed
failgood
fb-internal-demo
feed
firebase
flow
fluid-libraries
forkhandles
forum
fosdem
fp-in-kotlin
framework-elide
freenode
french
fritz2
fuchsia
functional
funktionale
gamedev
ge-kotlin
general-advice
georgia
geospatial
german-lang
getting-started
github-workflows-kt
glance
godot-kotlin
google-io
gradle
graphic
graphkool
graphql
graphql-kotlin
graviton-browser
greece
grpc
gsoc
gui
hackathons
hacktoberfest
hamburg
hamkrest
helios
helsinki
hexagon
hibernate
hikari-cp
hire-me
hiring
hongkong
hoplite
http4k
hungary
hyderabad
image-processing
india
indonesia
inkremental
intellij
intellij-plugins
intellij-tricks
internships
introduce-yourself
io
ios
iran
israel
istanbulcoders
italian
jackson-kotlin
jadx
japanese
jasync-sql
java-to-kotlin-refactoring
javadevelopers
javafx
javalin
javascript
jdbi
jhipster-kotlin
jobsworldwide
jpa
jshdq
juul-libraries
jvm-ir-backend-feedback
jxadapter
k2-early-adopters
kaal
kafka
kakao
kalasim
kapt
karachi
karg
karlsruhe
kash_shell
kaskade
kbuild
kdbc
kgen-doc-tools
kgraphql
kinta
klaxon
klock
kloudformation
kmdc
kmm-español
kmongo
knbt
knote
koalaql
koans
kobalt
kobweb
kodein
kodex
kohesive
koin
koin-dev
komapper
kondor-json
kong
kontent
kontributors
korau
korean
korge
korim
korio
korlibs
korte
kotest
kotest-contributors
kotless
kotlick
kotlin-asia
kotlin-beam
kotlin-by-example
kotlin-csv
kotlin-data-storage
kotlin-foundation
kotlin-fuel
kotlin-in-action
kotlin-inject
kotlin-latam
kotlin-logging
kotlin-multiplatform-contest
kotlin-mumbai
kotlin-native
kotlin-pakistan
kotlin-plugin
kotlin-pune
kotlin-roadmap
kotlin-samples
kotlin-sap
kotlin-serbia
kotlin-spark
kotlin-szeged
kotlin-website
kotlinacademy
kotlinbot
kotlinconf
kotlindl
kotlinforbeginners
kotlingforbeginners
kotlinlondon
kotlinmad
kotlinprogrammers
kotlinsu
kotlintest
kotlintest-devs
kotlintlv
kotlinultimatechallenge
kotlinx-datetime
kotlinx-files
kotlinx-html
kotrix
kotson
kovenant
kprompt
kraph
krawler
kroto-plus
ksp
ktcc
ktfmt
ktlint
ktor
ktp
kubed
kug-leads
kug-torino
kvision
kweb
lambdaworld_cadiz
lanark
language-evolution
language-proposals
latvia
leakcanary
leedskotlinusergroup
lets-have-fun
libgdx
libkgd
library-development
linkeddata
lithuania
london
losangeles
lottie
love
lychee
macedonia
machinelearningbawas
madrid
malaysia
mathematics
meetkotlin
memes
meta
metro-detroit
mexico
miami
micronaut
minnesota
minutest
mirror
mockk
moko
moldova
monsterpuzzle
montreal
moonbean
morocco
motionlayout
mpapt
mu
multiplatform
mumbai
munich
mvikotlin
mvrx
myndocs-oauth2-server
naming
navigation-architecture-component
nepal
new-mexico
new-zealand
newname
nigeria
nodejs
norway
npm-publish
nyc
oceania
ohio-kotlin-users
oldenburg
oolong
opensource
orbit-mvi
osgi
otpisani
package-search
pakistan
panamá
pattern-matching
pbandk
pdx
peru
philippines
phoenix
pinoy
pocketgitclient
polish
popkorn
portugal
practical-functional-programming
proguard
prozis-android-backup
pyhsikal
python
python-contributors
quasar
random
re
react
reaktive
realm
realworldkotlin
reductor
reduks
redux
redux-kotlin
refactoring-to-kotlin
reflect
refreshversions
reports
result
rethink
revolver
rhein-main
rocksdb
romania
room
rpi-pico
rsocket
russian
russian_feed
russian-kotlinasfirst
rx
rxjava
san-diego
science
scotland
scrcast
scrimage
script
scripting
seattle
serialization
server
sg-user-group
singapore
skia-wasm-interop-temp
skrape-it
slovak
snake
sofl-user-group
southafrica
spacemacs
spain
spanish
speaking
spek
spin
splitties
spotify-mobius
spring
spring-security
squarelibraries
stackoverflow
stacks
stayhungrystayfoolish
stdlib
stlouis
strife-discord-lib
strikt
students
stuttgart
sudan
swagger-gradle-codegen
swarm
sweden
swing
swiss-user-group
switzerland
talking-kotlin
tallinn
tampa
teamcity
tegal
tempe
tensorflow
terminal
test
testing
testtestest
texas
tgbotapi
thailand
tornadofx
touchlab-tools
training
tricity-kotlin-user-group
trójmiasto
truth
tunisia
turkey
turkiye
twitter-feed
uae
udacityindia
uk
ukrainian
uniflow
unkonf
uruguay
utah
uuid
vancouver
vankotlin
vertx
videos
vienna
vietnam
vim
vkug
vuejs
web-mpp
webassembly
webrtc
wimix_sentry
wwdc
zircon
Powered by Linen
moko
  • a

    Andy Gibel

    11/05/2019, 7:57 PM
    I've been using the moko-template project and it's been going way more smoothly than usual MPP project starters 🙂
    👍 2
    👏 1
    a
    • 2
    • 1
  • a

    Andy Gibel

    11/05/2019, 9:02 PM
    @Alex Pogrebnyak Any particular reason moko-network requires Android API 21?
    a
    a
    • 3
    • 8
  • a

    Andy Gibel

    11/06/2019, 12:35 AM
    Would it be easy enough to separated the generated API with the Models via moko-network?
    a
    • 2
    • 13
  • m

    Michal Harakal

    11/06/2019, 9:26 AM
    One issue, which Moko is solving realy nice are multiple frameworks for iOS, https://github.com/JetBrains/kotlin-native/issues/2423#issuecomment-550197856 this will be solved with 1.3.70 Am I right that to reflect this change with MoKo only a change in icerock plugins is required? Or put question other way around, no chnages in modules layout/struct will be required?
    a
    • 2
    • 2
  • a

    Andy Gibel

    11/10/2019, 5:56 AM
    I've added a lot to the mpp-library and Android works but now iOS build process gives me
    Command PhaseScriptExecution failed with a nonzero exit code
    a
    • 2
    • 15
  • a

    Andy Gibel

    11/14/2019, 8:41 PM
    at some point I changed something with the project and it stopped building the library Framework for iOS
    a
    • 2
    • 27
  • a

    Andy Gibel

    11/17/2019, 3:17 AM
    seems like 1.3.60 kotlin-gradle-plugin breaks moko
    setupFramework
    call
    a
    • 2
    • 3
  • a

    Andy Gibel

    11/19/2019, 4:24 PM
    So just some feedback FWIW. I think moko (template especially) saves some config headaches. However, what I would find really valuable is a medium article or something describing exactly what is going on in your DSLs. I know the source is available but just some discussion on why you chose this abstraction, what problems it's solving, future support plans, etc
    m
    a
    p
    • 4
    • 17
  • a

    Andy Gibel

    11/19/2019, 4:25 PM
    I also think a lot of the libraries you made have a lot of value but what is perhaps limiting their usefulness is a detailed description of the problem they solve and (even better) an example project highlighting only that component
    a
    • 2
    • 2
  • a

    Andy Gibel

    11/19/2019, 4:26 PM
    for instance I didn't really want to use your LiveData/MvvM stuff at the moment so the first thing I had to do was strip all of that out. The #1 thing missing from the K/N community is detailed, up-to-date documentation on how things are setup and why. I feel like you guys have the expertise and manpower to fill that gap if you chose to
    a
    • 2
    • 3
  • u

    4ntoine

    12/23/2019, 7:04 AM
    @alex009 Hi, Alex. I’m curious about moko-widgets. 2 Qs 1) Any list/screenshots of supported widget (without looking into the source code)? Found just a couple in https://github.com/icerockdev/moko-widgets 2) Anybody using it in production (in UI-rich apps)?
    a
    • 2
    • 2
  • u

    4ntoine

    12/23/2019, 7:07 AM
    Also is it correct that it’s an intersection of both platforms (that seems to be very limited)? I know one could use
    expect/actual
    , but anyway..
    a
    • 2
    • 6
  • n

    Nick Halase

    01/02/2020, 4:26 PM
    Thank you so much for this awesome collection of code and thorough documentation, this is all amazing stuff! I’m going to be using Widgets in my new project. Where would you like bug reports or suggestions? On GitHub? Here? Thanks!
    a
    • 2
    • 1
  • n

    Nick Halase

    01/08/2020, 4:16 PM
    Is it intentional or a bug that when I embed a list widget in a screen implementing navigation that the list completely covers the top navigation bar?
    a
    • 2
    • 8
  • s

    sendoav

    01/27/2020, 2:57 PM
    Hi all, I’ve started integrating Moko Resources in our mpp project and just wanted to know if there is any way to access a particular string providing its key. Imagine we declare the string action_go=“GO” in the strings.xml, we would like to access the resource providing the key “action_go”
    a
    • 2
    • 4
  • p

    Patrick Jackson

    02/04/2020, 8:22 PM
    Anyone get this error when syncing gradle?
    Extension of type 'LibraryExtension' does not exist. Currently registered extension types:
    a
    • 2
    • 3
  • c

    Christian Sousa

    04/02/2020, 3:50 PM
    Hello guys, can anyone give me some help regarding the
    moko-resources
    ? I’m trying to build my project but it always gives me the following:
    Object 'MR' has several compatible actual declarations in modules...
    a
    • 2
    • 21
  • a

    ahmetcj4

    04/12/2020, 10:08 PM
    About moko network: 1. Generator didn't generate headers, do I need to enable it somewhere or intentionally disabled? 2. One of the request needed to send object with type of List<String> and generated code doesn't include string list serializer import and failed. There was a list serializer instead. How can I include this?
    a
    • 2
    • 1
  • a

    ahmetcj4

    04/12/2020, 10:08 PM
    About moko widget: 1. I couldn't make bottom sheet working on iOS. It fails on pod update command. Works on Android. How can make it work on iOS? 2. When using constraint builder, I chained two buttons horizontally and give MatchConstraint width sizespec to both of them. Android produced buttons with same length but on iOS, one of the buttons behaves as wrap content and other button takes all the space. How can I make them take same space on ios?
    a
    • 2
    • 2
  • c

    Christian Sousa

    04/15/2020, 12:31 PM
    Could not determine the dependencies of task ':MyLib:linkDebugFrameworkIosArm32'.
    > Could not resolve all task dependencies for configuration ':MyLib:iosArm32CompileKlibraries'.
       > Could not resolve dev.icerock.moko:resources:0.9.1.
         Required by:
             project :MyLib
          > Unable to find a matching variant of dev.icerock.moko:resources:0.9.1:
              - Variant 'android-debugApiElements' capability dev.icerock.moko:resources:0.9.1:
                  - Incompatible attribute:
                      - Required org.jetbrains.kotlin.platform.type 'native' and found incompatible value 'androidJvm'.
                  - Other attributes:
                      - Found com.android.build.api.attributes.BuildTypeAttr 'debug' but wasn't required.
                      - Found com.android.build.api.attributes.VariantAttr 'debug' but wasn't required.
                      - Found com.android.build.gradle.internal.dependency.AndroidTypeAttr 'Aar' but wasn't required.
                      - Found org.gradle.status 'release' but wasn't required.
                      - Required org.gradle.usage 'kotlin-api' and found compatible value 'java-api'.
                      - Required org.jetbrains.kotlin.native.target 'ios_arm32' but no value provided.
              - Variant 'android-debugRuntimeElements' capability dev.icerock.moko:resources:0.9.1:
                  - Incompatible attribute:
                      - Required org.jetbrains.kotlin.platform.type 'native' and found incompatible value 'androidJvm'.
                  - Other attributes:
                      - Found com.android.build.api.attributes.BuildTypeAttr 'debug' but wasn't required.
                      - Found com.android.build.api.attributes.VariantAttr 'debug' but wasn't required.
                      - Found com.android.build.gradle.internal.dependency.AndroidTypeAttr 'Aar' but wasn't required.
                      - Found org.gradle.status 'release' but wasn't required.
                      - Required org.gradle.usage 'kotlin-api' and found compatible value 'java-runtime'.
                      - Required org.jetbrains.kotlin.native.target 'ios_arm32' but no value provided.
              - Variant 'android-releaseApiElements' capability dev.icerock.moko:resources:0.9.1:
                  - Incompatible attribute:
                      - Required org.jetbrains.kotlin.platform.type 'native' and found incompatible value 'androidJvm'.
                  - Other attributes:
                      - Found com.android.build.api.attributes.BuildTypeAttr 'release' but wasn't required.
                      - Found com.android.build.api.attributes.VariantAttr 'release' but wasn't required.
                      - Found com.android.build.gradle.internal.dependency.AndroidTypeAttr 'Aar' but wasn't required.
                      - Found org.gradle.status 'release' but wasn't required.
                      - Required org.gradle.usage 'kotlin-api' and found compatible value 'java-api'.
                      - Required org.jetbrains.kotlin.native.target 'ios_arm32' but no value provided.
              - Variant 'android-releaseRuntimeElements' capability dev.icerock.moko:resources:0.9.1:
                  - Incompatible attribute:
                      - Required org.jetbrains.kotlin.platform.type 'native' and found incompatible value 'androidJvm'.
                  - Other attributes:
                      - Found com.android.build.api.attributes.BuildTypeAttr 'release' but wasn't required.
                      - Found com.android.build.api.attributes.VariantAttr 'release' but wasn't required.
                      - Found com.android.build.gradle.internal.dependency.AndroidTypeAttr 'Aar' but wasn't required.
                      - Found org.gradle.status 'release' but wasn't required.
                      - Required org.gradle.usage 'kotlin-api' and found compatible value 'java-runtime'.
                      - Required org.jetbrains.kotlin.native.target 'ios_arm32' but no value provided.
              - Variant 'iosArm64-api' capability dev.icerock.moko:resources:0.9.1:
                  - Incompatible attribute:
                      - Required org.jetbrains.kotlin.native.target 'ios_arm32' and found incompatible value 'ios_arm64'.
                  - Other attributes:
                      - Found org.gradle.status 'release' but wasn't required.
                      - Required org.gradle.usage 'kotlin-api' and found compatible value 'kotlin-api'.
                      - Required org.jetbrains.kotlin.platform.type 'native' and found compatible value 'native'.
              - Variant 'iosX64-api' capability dev.icerock.moko:resources:0.9.1:
                  - Incompatible attribute:
                      - Required org.jetbrains.kotlin.native.target 'ios_arm32' and found incompatible value 'ios_x64'.
                  - Other attributes:
                      - Found org.gradle.status 'release' but wasn't required.
                      - Required org.gradle.usage 'kotlin-api' and found compatible value 'kotlin-api'.
                      - Required org.jetbrains.kotlin.platform.type 'native' and found compatible value 'native'.
              - Variant 'metadata-api' capability dev.icerock.moko:resources:0.9.1:
                  - Incompatible attribute:
                      - Required org.jetbrains.kotlin.platform.type 'native' and found incompatible value 'common'.
                  - Other attributes:
                      - Found org.gradle.status 'release' but wasn't required.
                      - Required org.gradle.usage 'kotlin-api' and found compatible value 'kotlin-api'.
                      - Required org.jetbrains.kotlin.native.target 'ios_arm32' but no value provided.
    a
    • 2
    • 3
  • s

    SrSouza

    06/25/2020, 8:15 PM
    Hi folks, do you think in use Jetpack Compose in the future to Draw the UI porting it to Kotlin Native?
    v
    • 2
    • 2
  • g

    Glen

    09/03/2020, 12:20 PM
    Hello everyone. Please, I would like to know more about moko-widgets. It seems really interesting and I would like to try it out.
    a
    • 2
    • 5
  • a

    alex009

    10/21/2020, 2:32 PM
    ℹ️ at now all moko libs except moko-widgets available on kotlin 1.4. you may check it on github or on https://libs.kmp.icerock.dev
    👍 5
    • 1
    • 1
  • j

    Julius

    12/02/2020, 5:01 PM
    Hello, I'm currently trying to implement the moko-resources but I keep receiving the gradle error: Required value was null.
    a
    • 2
    • 10
  • l

    ludOS

    01/09/2021, 6:55 PM
    hello hello, Soon I'll resume work trying to get moko working on the iOS part of this project that was setup pre kotlin 1.4. First order of business will probably be to relaunch the new project wizard and put files in a proper hierarchy. Anyway, if anyone wants to have a look, code is LGPL: https://github.com/f8full/herdr
    a
    • 2
    • 12
  • a

    alex009

    01/11/2021, 6:27 AM
    https://twitter.com/alex009ru/status/1348291921266012160?s=21
    👍 3
    👏 2
    :kotlin: 2
    b
    • 2
    • 5
  • s

    solidogen

    05/21/2021, 1:26 PM
    hi, what is the current state of moko-widgets? idea seems great, yet complexity level would be similar to Xamarin.Forms, which is a lot to take on and time consuming
    g
    a
    s
    • 4
    • 11
  • x

    xxfast

    06/05/2021, 1:18 AM
    Hello, Re:
    moko:resource-generator
    and
    moko:resources
    , when can we expect
    0.16.0
    with jvm target support to be available?
    a
    • 2
    • 2
  • b

    borisdamato

    07/13/2021, 1:34 PM
    Hello! What is the recommended way to use
    moko-resources
    in a multi-module setup? In my project I have multiple multiplatform modules (usually split by feature) and then I’m using the umbrella framework approach to integrate them into iOS as a single framework. The problem is that when I use
    moko-resources
    on more than one module, of course I end up with multiple
    MR_, MR__, etc
    on the Swift side. What’s the recommended approach with this setup? Thanks
    a
    • 2
    • 1
  • z

    Zhiqiang Bian

    07/14/2021, 9:36 PM
    Hi! I am using moko livedata (version 0.10.1) with databinding in layout.xml. Can I ask how to refer to a LiveData as shown in the screenshots below? I tried
    android:text="viewModel.station.ld().name"
    and
    android:text="viewModel.station.ld.name"
    . The initial value can be read correctly, but it never updates.
    y
    a
    • 3
    • 5
Powered by Linen
Title
z

Zhiqiang Bian

07/14/2021, 9:36 PM
Hi! I am using moko livedata (version 0.10.1) with databinding in layout.xml. Can I ask how to refer to a LiveData as shown in the screenshots below? I tried
android:text="viewModel.station.ld().name"
and
android:text="viewModel.station.ld.name"
. The initial value can be read correctly, but it never updates.
y

y9san9

07/15/2021, 3:49 AM
Despite of the IDE highlighting, try to compile this 🙂
👍 1
I came across this issue resently and this compiles fine, I think the reason is that there is also LiveData in common code that has no
ld()
method
a

alex009

07/15/2021, 1:38 PM
updates will work only if databinding have setted lifecycle. https://developer.android.com/topic/libraries/data-binding/architecture#livedata
in moko-mvvm it's done here - https://github.com/icerockdev/moko-mvvm/blob/master/mvvm-databinding/src/main/kotlin/dev/icerock/moko/mvvm/MvvmActivity.kt#L32
z

Zhiqiang Bian

08/02/2021, 1:58 PM
Thanks for your explanation! I did more experiment and found
.ld
works fine, while
.ld()
does not.
View count: 5