What's the difference between viewBinding enabled true and buildfeatures viewBinding true

Viewed 34

What's the difference between the options to enable viewBinding:

viewBinding {
    enabled = true
}

AND

Groovy

buildFeatures {
    viewBinding true
}

Kotlin

buildFeatures {
    viewBinding = true
}
1 Answers
viewBinding {
    enabled = true
}

this used to be used and now some users are seeing error

buildFeatures {
    viewBinding = true
}

they are using this. But there is no difference in terms of usage.

Related