var data = MutableLiveData<Salt>()
This is the code as simple as that , i am trying to write and test my code in IntelliJ because is more faster and convinient for me .But i get an exception when trying to call mutable live data.
Unresolved Reference:MutableLive Data
and intelliJ doesn't seem to find de libraries by default , i looked online and it seems i have to get the android and gradle module on the project , i already installed all the modules gradle has by default on a community intellij but it is still unable to find it. I could not install the android module, i clicked on install android sdk as it told me but it is stuck on this message
reparing "Install Android Support Repository (revision: 47.0.0)". Downloading https://dl.google.com/android/repository/android_m2repository_r47.zip
it never downloads , i downloaded the file by hand , if someone knows how to install it by hand, that would be great. If there is a simpler way to use the MutableLiveDatatype , that would also help, i only want to use that on IntelliJ on a kotlin project is as simple as that.
The issue is, that is not the correct syntax of declaring a variable in Kotlin.
Should be: var data = MutableLiveData<Salt>()
.
Also, i'll strongly advice you use Android Studio which was designed specifically for Android development.