Add this to project level build.gradle
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
Add the dependency into you app level build.gradle
dependencies {
implementation 'com.github.harunbekcan:EasyDatePicker:VersionName'
}
private var startDate = Calendar.getInstance()
private val startDateListener = MutableLiveData<String>()
EasyDatePicker(this)
.setDate(startDate)
.setDatePickerStyle(R.style.StyleExample)
.setFormatType(DATE_FORMAT)
.setListener(startDateListener)
.setEditText(findViewById(R.id.startDateEditText))
.show()