Monday, 24 April 2017

How to convert dot notation to string?

I was looking for a way to convert something in dot notation into a string using Javascript. Basically here's what I am looking for:

function dotToString(dotNotation){
  return something;
}


dotToString(this.is.just.a.test);
// Would return "this.is.just.a.test"

Thanks so much!



via Josh Feinsilber

No comments:

Post a Comment