Why I can't pass variable in daterangepicker?

Why I can't pass variable in daterangepicker?

Hello!
I have daterangepicker on my website:
  

  1. $('#first_range').daterangepicker({
  2. startDate: moment(Elastic.periods[".second"].range["Purchase Date/Time"].gte, "YYYY-MM-DD"),
  3. endDate: moment(Elastic.periods[".second"].range["Purchase Date/Time"].lte, "YYYY-MM-DD"),
  4. ranges: rang,
  5. "locale": datelink
  6. }, cb1);

  7. cb1(start, end);
I'm trying to translate this datepicker to other languages. Due to this I created json files with translations(rang and datelink).
Doing this way causes error:
   
  1. jQuery.Deferred exception: rang is not defined ReferenceError: rang is not defined
Rang and datelink are links to json files with languages and they are defined.
Is it impossible to pass variable into datepicker or I have errors in my code?