Closed sleepycat closed 9 years ago
This method registers a callback function that will be called when the labels a being applied. This means that in cases where datum.label is an object like {en: "", fr: ""}, there is a way to select the right attribute.
Usage:
.labelFunction(function(label){ return label[currentLocale];})
I'm happy to rework this if you have some changes/improvements you would like me to make.
Thanks!
This method registers a callback function that will be called when the labels a being applied. This means that in cases where datum.label is an object like {en: "", fr: ""}, there is a way to select the right attribute.
Usage:
.labelFunction(function(label){ return label[currentLocale];})
I'm happy to rework this if you have some changes/improvements you would like me to make.