{"id":1115,"date":"2013-06-12T12:30:37","date_gmt":"2013-06-12T12:30:37","guid":{"rendered":"http:\/\/garysieling.com\/blog\/?p=1115"},"modified":"2013-06-12T12:30:37","modified_gmt":"2013-06-12T12:30:37","slug":"parsing-javascript-in-javascript","status":"publish","type":"post","link":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/","title":{"rendered":"Parsing Javascript in Javascript"},"content":{"rendered":"<p>Closures are a language feature which allow the programmer to inject static variables into a function\u2019s scope, without the use of method parameters. E.g.:<\/p>\n<pre lang=\"Javascript\">\na = \"b\";\nfunction c() { return a; }\nc()\n\"b\"\n<\/pre>\n<p>A common pattern is to return a second function, using arguments from the first: <\/p>\n<pre lang=\"Javascript\">\nfunction c(a) { \n  return function f(b) { \n    return a + b; \n  } \n}\nc(5)(8)\n13\n<\/pre>\n<p>This is a powerful construct, as it lets you essentially create custom functions. The downside is that closed variables are difficult to discover in the browser, without the use of the debugger.  If a library is built entirely from closures, it will hand you objects that appear to have no state, since the state is contained within functions &#8211; this is how D3.js works (To D3\u2019s credit, it does offer plenty of options to expose the data). A worse scenario is a mix, where a few items of state are hidden from the developer, but most are visible.<\/p>\n<p>Since it\u2019s trivial to convert a function back to a string, I thought a first step to fixing this might be parsing the javascript, to determine which values are closures. Once you have this information, you can be aware of the issue, and if you could run code within that function\u2019s context, you could log the values.<\/p>\n<p>There are a few parsers available already, because any library that minifies or analyzes code requires this. <a href=\"http:\/\/www.amazon.com\/gp\/product\/0596517742\/ref=as_li_ss_tl?ie=UTF8&#038;camp=1789&#038;creative=390957&#038;creativeASIN=0596517742&#038;linkCode=as2&#038;tag=thesecrelifeo-20\">JSLint<\/a> already parses Javascript, and exposes the results:<\/p>\n<pre lang=\"Javascript\">\nJSLINT.jslint(\u201cvar a = 1\u201d)\nJSLINT.data()\n<\/pre>\n<p>Here is an example from the parse tree, representing a single &#8220;var&#8221; keyword:<\/p>\n<pre>\n1: Object\ndead: false\nfrom: 10\nfunction: Object\nidentifier: true\ninit: true\nkind: \"var\"\nline: 1\nmaster: undefined\nstatement: true\nstring: \"c\"\nthru: 11\nused: 0\nwriteable: false\n<\/pre>\n<p>If you want to just inspect a single function\u2019s contents, there is no guarantee this will be able to find a closure, since we\u2019re parsing bits of javascript code. Consequently, what I\u2019m demonstrating here will return the superset of all closed variables, but practically speaking it\u2019s pretty good.<\/p>\n<p>Consider this example:<\/p>\n<pre lang=\"Javascript\">\na = \"b\";\n\"b\"\nfunction c() { return a; }\nc()\n\"b\"\nd = c.toString()\n\"function c() { return a; }\"\n\nJSLINT.jslint(d)\nJSLINT.data()\n<\/pre>\n<p>If we just run this on a function on it\u2019s own (what I want to do) we have a problem &#8211; this isn\u2019t a closure at all, but a function with an undefined variable. I\u2019m going to assume the library I\u2019m analyzing works though, and count this as good enough.<\/p>\n<pre lang=\"Javascript\">\nvar text = \"function c(){ return a; } \"\n\n$.each(JSLINT.data().errors, function f(i, obj) {\n  var err = \"'{\" + obj.a + \"}'\" + \" was used before it was defined.\"\n  if (err === obj.raw) {\n     console.log(\"Possible Closure: \" + obj.a);\n  }\n })\n\nPossible Closure: a\n<\/pre>\n<p>And it works! <\/p>\n<p>In the second example, we\u2019ll define the variable. Strictly speaking \u201ca\u201d is a global, but if this was extracted from deep within a library, it might be a closure. You can inspect the JSLint results of this to find this first class of closures:<\/p>\n<pre lang=\"Javascript\">\nvar text = \"var a = 'b'; function c(){ return a; } \"\n\n$.each(JSLINT.data().tokens, function f(i, obj) {\n  if ('function' === obj.kind) {\n     console.log(obj.function.global);\n  }\n })\n\n[\"a\"]\n<\/pre>\n<p>Now, just for completeness, consider a real closure, which JSLint can find on its own:<\/p>\n<pre lang=\"Javascript\">\nvar text = \"function f() { var a = 'b'; function c(){ return a; } }\"\n\n$.each(JSLINT.data().tokens, function f(i, obj) {\n  if ('function' === obj.kind && obj.function.closure && obj.function.closure.length > 0) {\n     console.log(obj.function.closure);\n  }\n })\n[\"a\"]\n<\/pre>\n<p>At this point, I\u2019m not sure what you can do with this information, but at least it demonstrates some interesting issues.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Closures are a language feature which allow the programmer to inject static variables into a function\u2019s scope, without the use of method parameters. E.g.: a = &#8220;b&#8221;; function c() { return a; } c() &#8220;b&#8221; A common pattern is to return a second function, using arguments from the first: function c(a) { return function f(b) &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Parsing Javascript in Javascript&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"footnotes":""},"categories":[13,29],"tags":[138,321,440],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 4.9.9 - aioseo.com -->\n\t<meta name=\"description\" content=\"Closures are a language feature which allow the programmer to inject static variables into a function\u2019s scope, without the use of method parameters. E.g.: a = &quot;b&quot;; function c() { return a; } c() &quot;b&quot; A common pattern is to return a second function, using arguments from the first: function c(a) { return function f(b)\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"gary\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 4.9.9\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"Gary Sieling - Software Engineer\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"Parsing Javascript in Javascript - Gary Sieling\" \/>\n\t\t<meta property=\"og:description\" content=\"Closures are a language feature which allow the programmer to inject static variables into a function\u2019s scope, without the use of method parameters. E.g.: a = &quot;b&quot;; function c() { return a; } c() &quot;b&quot; A common pattern is to return a second function, using arguments from the first: function c(a) { return function f(b)\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2013-06-12T12:30:37+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2013-06-12T12:30:37+00:00\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n\t\t<meta name=\"twitter:title\" content=\"Parsing Javascript in Javascript - Gary Sieling\" \/>\n\t\t<meta name=\"twitter:description\" content=\"Closures are a language feature which allow the programmer to inject static variables into a function\u2019s scope, without the use of method parameters. E.g.: a = &quot;b&quot;; function c() { return a; } c() &quot;b&quot; A common pattern is to return a second function, using arguments from the first: function c(a) { return function f(b)\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"BlogPosting\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/parsing-javascript-in-javascript\\\/#blogposting\",\"name\":\"Parsing Javascript in Javascript - Gary Sieling\",\"headline\":\"Parsing Javascript in Javascript\",\"author\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/author\\\/gary\\\/#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/#organization\"},\"datePublished\":\"2013-06-12T12:30:37+00:00\",\"dateModified\":\"2013-06-12T12:30:37+00:00\",\"inLanguage\":\"en-US\",\"commentCount\":2,\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/parsing-javascript-in-javascript\\\/#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/parsing-javascript-in-javascript\\\/#webpage\"},\"articleSection\":\"Javascript Code Examples, Thought Experiments, d3.js, jslint, programming techniques\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/parsing-javascript-in-javascript\\\/#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.garysieling.com\\\/blog\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/category\\\/javascript-code-examples\\\/#listItem\",\"name\":\"Javascript Code Examples\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/category\\\/javascript-code-examples\\\/#listItem\",\"position\":2,\"name\":\"Javascript Code Examples\",\"item\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/category\\\/javascript-code-examples\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/parsing-javascript-in-javascript\\\/#listItem\",\"name\":\"Parsing Javascript in Javascript\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/parsing-javascript-in-javascript\\\/#listItem\",\"position\":3,\"name\":\"Parsing Javascript in Javascript\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/category\\\/javascript-code-examples\\\/#listItem\",\"name\":\"Javascript Code Examples\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/#organization\",\"name\":\"Gary Sieling\",\"description\":\"Software Engineer\",\"url\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/author\\\/gary\\\/#author\",\"url\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/author\\\/gary\\\/\",\"name\":\"gary\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/parsing-javascript-in-javascript\\\/#authorImage\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/0be925276d848ffe98a6a9dc8cf33e67?s=96&d=identicon&r=g\",\"width\":96,\"height\":96,\"caption\":\"gary\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/parsing-javascript-in-javascript\\\/#webpage\",\"url\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/parsing-javascript-in-javascript\\\/\",\"name\":\"Parsing Javascript in Javascript - Gary Sieling\",\"description\":\"Closures are a language feature which allow the programmer to inject static variables into a function\\u2019s scope, without the use of method parameters. E.g.: a = \\\"b\\\"; function c() { return a; } c() \\\"b\\\" A common pattern is to return a second function, using arguments from the first: function c(a) { return function f(b)\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/parsing-javascript-in-javascript\\\/#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/author\\\/gary\\\/#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/author\\\/gary\\\/#author\"},\"datePublished\":\"2013-06-12T12:30:37+00:00\",\"dateModified\":\"2013-06-12T12:30:37+00:00\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/\",\"name\":\"Gary Sieling\",\"description\":\"Software Engineer\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Parsing Javascript in Javascript - Gary Sieling","description":"Closures are a language feature which allow the programmer to inject static variables into a function\u2019s scope, without the use of method parameters. E.g.: a = \"b\"; function c() { return a; } c() \"b\" A common pattern is to return a second function, using arguments from the first: function c(a) { return function f(b)","canonical_url":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"BlogPosting","@id":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/#blogposting","name":"Parsing Javascript in Javascript - Gary Sieling","headline":"Parsing Javascript in Javascript","author":{"@id":"https:\/\/www.garysieling.com\/blog\/author\/gary\/#author"},"publisher":{"@id":"https:\/\/www.garysieling.com\/blog\/#organization"},"datePublished":"2013-06-12T12:30:37+00:00","dateModified":"2013-06-12T12:30:37+00:00","inLanguage":"en-US","commentCount":2,"mainEntityOfPage":{"@id":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/#webpage"},"isPartOf":{"@id":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/#webpage"},"articleSection":"Javascript Code Examples, Thought Experiments, d3.js, jslint, programming techniques"},{"@type":"BreadcrumbList","@id":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog#listItem","position":1,"name":"Home","item":"https:\/\/www.garysieling.com\/blog","nextItem":{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog\/category\/javascript-code-examples\/#listItem","name":"Javascript Code Examples"}},{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog\/category\/javascript-code-examples\/#listItem","position":2,"name":"Javascript Code Examples","item":"https:\/\/www.garysieling.com\/blog\/category\/javascript-code-examples\/","nextItem":{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/#listItem","name":"Parsing Javascript in Javascript"},"previousItem":{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/#listItem","position":3,"name":"Parsing Javascript in Javascript","previousItem":{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog\/category\/javascript-code-examples\/#listItem","name":"Javascript Code Examples"}}]},{"@type":"Organization","@id":"https:\/\/www.garysieling.com\/blog\/#organization","name":"Gary Sieling","description":"Software Engineer","url":"https:\/\/www.garysieling.com\/blog\/"},{"@type":"Person","@id":"https:\/\/www.garysieling.com\/blog\/author\/gary\/#author","url":"https:\/\/www.garysieling.com\/blog\/author\/gary\/","name":"gary","image":{"@type":"ImageObject","@id":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/#authorImage","url":"https:\/\/secure.gravatar.com\/avatar\/0be925276d848ffe98a6a9dc8cf33e67?s=96&d=identicon&r=g","width":96,"height":96,"caption":"gary"}},{"@type":"WebPage","@id":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/#webpage","url":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/","name":"Parsing Javascript in Javascript - Gary Sieling","description":"Closures are a language feature which allow the programmer to inject static variables into a function\u2019s scope, without the use of method parameters. E.g.: a = \"b\"; function c() { return a; } c() \"b\" A common pattern is to return a second function, using arguments from the first: function c(a) { return function f(b)","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/www.garysieling.com\/blog\/#website"},"breadcrumb":{"@id":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/#breadcrumblist"},"author":{"@id":"https:\/\/www.garysieling.com\/blog\/author\/gary\/#author"},"creator":{"@id":"https:\/\/www.garysieling.com\/blog\/author\/gary\/#author"},"datePublished":"2013-06-12T12:30:37+00:00","dateModified":"2013-06-12T12:30:37+00:00"},{"@type":"WebSite","@id":"https:\/\/www.garysieling.com\/blog\/#website","url":"https:\/\/www.garysieling.com\/blog\/","name":"Gary Sieling","description":"Software Engineer","inLanguage":"en-US","publisher":{"@id":"https:\/\/www.garysieling.com\/blog\/#organization"}}]},"og:locale":"en_US","og:site_name":"Gary Sieling - Software Engineer","og:type":"article","og:title":"Parsing Javascript in Javascript - Gary Sieling","og:description":"Closures are a language feature which allow the programmer to inject static variables into a function\u2019s scope, without the use of method parameters. E.g.: a = &quot;b&quot;; function c() { return a; } c() &quot;b&quot; A common pattern is to return a second function, using arguments from the first: function c(a) { return function f(b)","og:url":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/","article:published_time":"2013-06-12T12:30:37+00:00","article:modified_time":"2013-06-12T12:30:37+00:00","twitter:card":"summary_large_image","twitter:title":"Parsing Javascript in Javascript - Gary Sieling","twitter:description":"Closures are a language feature which allow the programmer to inject static variables into a function\u2019s scope, without the use of method parameters. E.g.: a = &quot;b&quot;; function c() { return a; } c() &quot;b&quot; A common pattern is to return a second function, using arguments from the first: function c(a) { return function f(b)"},"aioseo_meta_data":{"post_id":"1115","title":null,"description":null,"keywords":null,"keyphrases":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"","isEnabled":true},"graphs":[]},"schema_type":"default","schema_type_options":null,"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"limit_modified_date":false,"created":"2023-02-04 16:16:28","updated":"2026-07-06 00:57:38","ai":null,"breadcrumb_settings":null,"seo_analyzer_scan_date":null},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.garysieling.com\/blog\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.garysieling.com\/blog\/category\/javascript-code-examples\/\" title=\"Javascript Code Examples\">Javascript Code Examples<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tParsing Javascript in Javascript\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/www.garysieling.com\/blog"},{"label":"Javascript Code Examples","link":"https:\/\/www.garysieling.com\/blog\/category\/javascript-code-examples\/"},{"label":"Parsing Javascript in Javascript","link":"https:\/\/www.garysieling.com\/blog\/parsing-javascript-in-javascript\/"}],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts\/1115"}],"collection":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/comments?post=1115"}],"version-history":[{"count":0,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts\/1115\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/media?parent=1115"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/categories?post=1115"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/tags?post=1115"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}