Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Difference between ko.validation.configure vs ko.validation.init

Both are used to apply the knockout validation configurations on viewmodel. What is the different between these two statements?

Thanks

like image 866
Nexus23 Avatar asked Oct 02 '22 11:10

Nexus23


1 Answers

I looks like configure is there for backwards compatibility, and just calls init.

From the validation source (https://github.com/Knockout-Contrib/Knockout-Validation/blob/master/Src/api.js#L120):

        // backwards compatability
        configure: function (options) { ko.validation.init(options); },
like image 74
pax162 Avatar answered Oct 18 '22 08:10

pax162