Last active
December 8, 2015 12:39
-
-
Save kevupton/a5a2f37319f6aa1c2f2c to your computer and use it in GitHub Desktop.
Woooo
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function cus_func(input, search) { | |
var list = search.split(/[\[\]\.]/); | |
var new_key; | |
for (var key in list) { | |
new_key = list[key].replace(/^['"](.*?)['"]$/gm, '$1'); | |
input = ImageHelper.get(input, new_key); | |
} | |
console.log(input); | |
} | |
cus_fun(this.props.post, '_embedded["http://api.w.org/featuredmedia"][0].source_url'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment