{"id":633,"date":"2010-05-03T14:43:41","date_gmt":"2010-05-03T09:13:41","guid":{"rendered":"http:\/\/www.tothenew.com\/blog\/?p=633"},"modified":"2016-12-19T15:28:30","modified_gmt":"2016-12-19T09:58:30","slug":"injecting-method-to-trim-string-length-on-gsp-pages","status":"publish","type":"post","link":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/","title":{"rendered":"Injecting Method to trim string length on gsp pages"},"content":{"rendered":"<p>Restricting the length of a string on gsps is a common scenario in most of our projects.<br \/>\nGroovy&#8217;s metaprogramming magic made it too simple for me. I added the following lines of code to Bootstrap.groovy:<\/p>\n<pre lang=\"groovy\">\r\nObject.metaClass.trimLength = {Integer stringLength ->\r\n\r\n    String trimString = delegate?.toString()\r\n    String concatenateString = \"...\"\r\n    List separators = [\".\", \" \"]\r\n\r\n    if (stringLength && (trimString?.length() > stringLength)) {\r\n        trimString = trimString.substring(0, stringLength - concatenateString.length())\r\n        String separator = separators.findAll{trimString.contains(it)}?.min{trimString.lastIndexOf(it)}\r\n        if(separator){\r\n            trimString = trimString.substring(0, trimString.lastIndexOf(separator))\r\n        }\r\n        trimString += concatenateString\r\n    }\r\n    return trimString\r\n}\r\n<\/pre>\n<p>Now, for an instance of class Person: <\/p>\n<pre lang=\"groovy\">\r\nclass Person {\r\n    String name\r\n\r\n    String toString(){\r\n        return name\r\n    }\r\n}\r\n\r\nPerson person = new Person(name: \"Aman Aggarwal\")\r\n<\/pre>\n<p>I can simply write this code in gsp: <\/p>\n<pre lang=\"groovy\">\r\nperson.trimLength(10)\r\n<\/pre>\n<p>which renders output:<\/p>\n<pre lang=\"groovy\">\r\nAman...\r\n<\/pre>\n<p>Hope it helps.<\/p>\n<p>~Aman Aggarwal<br \/>\naman@intelligrape.com<\/p>\n<blockquote class=\"wp-embedded-content\" data-secret=\"abpw3USTs3\"><p><a href=\"https:\/\/www.tothenew.com\/blog\/\">Home<\/a><\/p><\/blockquote>\n<p><iframe loading=\"lazy\" class=\"wp-embedded-content\" sandbox=\"allow-scripts\" security=\"restricted\" style=\"position: absolute; visibility: hidden;\" title=\"\u201cHome\u201d \u2014 TO THE NEW Blog\" src=\"https:\/\/www.tothenew.com\/blog\/embed\/#?secret=72k6GLBf6h#?secret=abpw3USTs3\" data-secret=\"abpw3USTs3\" width=\"600\" height=\"338\" frameborder=\"0\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\"><\/iframe><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Restricting the length of a string on gsps is a common scenario in most of our projects. Groovy&#8217;s metaprogramming magic made it too simple for me. I added the following lines of code to Bootstrap.groovy: Object.metaClass.trimLength = {Integer stringLength -> String trimString = delegate?.toString() String concatenateString = &#8220;&#8230;&#8221; List separators = [&#8220;.&#8221;, &#8221; &#8220;] if [&hellip;]<\/p>\n","protected":false},"author":282,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"iawp_total_views":6,"footnotes":""},"categories":[7],"tags":[4840,9,32,145],"class_list":["post-633","post","type-post","status-publish","format-standard","hentry","category-grails","tag-grails","tag-groovy","tag-gsp","tag-metaprogramming"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.0.1 - aioseo.com -->\n\t<meta name=\"description\" content=\"Restricting the length of a string on gsps is a common scenario in most of our projects. Groovy&#039;s metaprogramming magic made it too simple for me. I added the following lines of code to Bootstrap.groovy: Object.metaClass.trimLength = {Integer stringLength -&gt; String trimString = delegate?.toString() String concatenateString = &quot;...&quot; List separators = [&quot;.&quot;, &quot; &quot;] if\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Aman Aggarwal\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.0.1\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"TO THE NEW BLOG\" \/>\n\t\t<meta property=\"og:type\" content=\"blog\" \/>\n\t\t<meta property=\"og:title\" content=\"Injecting Method to trim string length on gsp pages | TO THE NEW Blog\" \/>\n\t\t<meta property=\"og:description\" content=\"Restricting the length of a string on gsps is a common scenario in most of our projects. Groovy&#039;s metaprogramming magic made it too simple for me. I added the following lines of code to Bootstrap.groovy: Object.metaClass.trimLength = {Integer stringLength -&gt; String trimString = delegate?.toString() String concatenateString = &quot;...&quot; List separators = [&quot;.&quot;, &quot; &quot;] if\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/\" \/>\n\t\t<meta property=\"og:image\" content=\"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png\" \/>\n\t\t<meta property=\"og:image:secure_url\" content=\"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary\" \/>\n\t\t<meta name=\"twitter:site\" content=\"@tothenew\" \/>\n\t\t<meta name=\"twitter:title\" content=\"Injecting Method to trim string length on gsp pages | TO THE NEW Blog\" \/>\n\t\t<meta name=\"twitter:description\" content=\"Restricting the length of a string on gsps is a common scenario in most of our projects. Groovy&#039;s metaprogramming magic made it too simple for me. I added the following lines of code to Bootstrap.groovy: Object.metaClass.trimLength = {Integer stringLength -&gt; String trimString = delegate?.toString() String concatenateString = &quot;...&quot; List separators = [&quot;.&quot;, &quot; &quot;] if\" \/>\n\t\t<meta name=\"twitter:image\" content=\"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/injecting-method-to-trim-string-length-on-gsp-pages\\\/#article\",\"name\":\"Injecting Method to trim string length on gsp pages | TO THE NEW Blog\",\"headline\":\"Injecting Method to trim string length on gsp pages\",\"author\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/aman-2\\\/#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#organization\"},\"datePublished\":\"2010-05-03T14:43:41+05:30\",\"dateModified\":\"2016-12-19T15:28:30+05:30\",\"inLanguage\":\"en-US\",\"commentCount\":3,\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/injecting-method-to-trim-string-length-on-gsp-pages\\\/#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/injecting-method-to-trim-string-length-on-gsp-pages\\\/#webpage\"},\"articleSection\":\"Grails, Grails, Groovy, gsp, MetaProgramming\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/injecting-method-to-trim-string-length-on-gsp-pages\\\/#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.tothenew.com\\\/blog\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/#listItem\",\"name\":\"Grails\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/#listItem\",\"position\":2,\"name\":\"Grails\",\"item\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/injecting-method-to-trim-string-length-on-gsp-pages\\\/#listItem\",\"name\":\"Injecting Method to trim string length on gsp pages\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/injecting-method-to-trim-string-length-on-gsp-pages\\\/#listItem\",\"position\":3,\"name\":\"Injecting Method to trim string length on gsp pages\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/#listItem\",\"name\":\"Grails\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#organization\",\"name\":\"TO THE NEW Blog\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/aman-2\\\/#author\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/aman-2\\\/\",\"name\":\"Aman Aggarwal\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/injecting-method-to-trim-string-length-on-gsp-pages\\\/#authorImage\",\"url\":\"https:\\\/\\\/newersworld-sf-static.tothenew.net\\\/prod\\\/profilePicFolder\\\/66589b6a-51bb-47a9-98a1-5921aac69bd9_aman.aggarwal@tothenew.com.jpg\",\"width\":96,\"height\":96,\"caption\":\"Aman Aggarwal\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/injecting-method-to-trim-string-length-on-gsp-pages\\\/#webpage\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/injecting-method-to-trim-string-length-on-gsp-pages\\\/\",\"name\":\"Injecting Method to trim string length on gsp pages | TO THE NEW Blog\",\"description\":\"Restricting the length of a string on gsps is a common scenario in most of our projects. Groovy's metaprogramming magic made it too simple for me. I added the following lines of code to Bootstrap.groovy: Object.metaClass.trimLength = {Integer stringLength -> String trimString = delegate?.toString() String concatenateString = \\\"...\\\" List separators = [\\\".\\\", \\\" \\\"] if\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/injecting-method-to-trim-string-length-on-gsp-pages\\\/#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/aman-2\\\/#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/aman-2\\\/#author\"},\"datePublished\":\"2010-05-03T14:43:41+05:30\",\"dateModified\":\"2016-12-19T15:28:30+05:30\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/\",\"name\":\"TO THE NEW Blog\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Injecting Method to trim string length on gsp pages | TO THE NEW Blog","description":"Restricting the length of a string on gsps is a common scenario in most of our projects. Groovy's metaprogramming magic made it too simple for me. I added the following lines of code to Bootstrap.groovy: Object.metaClass.trimLength = {Integer stringLength -> String trimString = delegate?.toString() String concatenateString = \"...\" List separators = [\".\", \" \"] if","canonical_url":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/#article","name":"Injecting Method to trim string length on gsp pages | TO THE NEW Blog","headline":"Injecting Method to trim string length on gsp pages","author":{"@id":"https:\/\/www.tothenew.com\/blog\/author\/aman-2\/#author"},"publisher":{"@id":"https:\/\/www.tothenew.com\/blog\/#organization"},"datePublished":"2010-05-03T14:43:41+05:30","dateModified":"2016-12-19T15:28:30+05:30","inLanguage":"en-US","commentCount":3,"mainEntityOfPage":{"@id":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/#webpage"},"isPartOf":{"@id":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/#webpage"},"articleSection":"Grails, Grails, Groovy, gsp, MetaProgramming"},{"@type":"BreadcrumbList","@id":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog#listItem","position":1,"name":"Home","item":"https:\/\/www.tothenew.com\/blog","nextItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/category\/grails\/#listItem","name":"Grails"}},{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/category\/grails\/#listItem","position":2,"name":"Grails","item":"https:\/\/www.tothenew.com\/blog\/category\/grails\/","nextItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/#listItem","name":"Injecting Method to trim string length on gsp pages"},"previousItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/#listItem","position":3,"name":"Injecting Method to trim string length on gsp pages","previousItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/category\/grails\/#listItem","name":"Grails"}}]},{"@type":"Organization","@id":"https:\/\/www.tothenew.com\/blog\/#organization","name":"TO THE NEW Blog","url":"https:\/\/www.tothenew.com\/blog\/"},{"@type":"Person","@id":"https:\/\/www.tothenew.com\/blog\/author\/aman-2\/#author","url":"https:\/\/www.tothenew.com\/blog\/author\/aman-2\/","name":"Aman Aggarwal","image":{"@type":"ImageObject","@id":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/#authorImage","url":"https:\/\/newersworld-sf-static.tothenew.net\/prod\/profilePicFolder\/66589b6a-51bb-47a9-98a1-5921aac69bd9_aman.aggarwal@tothenew.com.jpg","width":96,"height":96,"caption":"Aman Aggarwal"}},{"@type":"WebPage","@id":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/#webpage","url":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/","name":"Injecting Method to trim string length on gsp pages | TO THE NEW Blog","description":"Restricting the length of a string on gsps is a common scenario in most of our projects. Groovy's metaprogramming magic made it too simple for me. I added the following lines of code to Bootstrap.groovy: Object.metaClass.trimLength = {Integer stringLength -> String trimString = delegate?.toString() String concatenateString = \"...\" List separators = [\".\", \" \"] if","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/www.tothenew.com\/blog\/#website"},"breadcrumb":{"@id":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/#breadcrumblist"},"author":{"@id":"https:\/\/www.tothenew.com\/blog\/author\/aman-2\/#author"},"creator":{"@id":"https:\/\/www.tothenew.com\/blog\/author\/aman-2\/#author"},"datePublished":"2010-05-03T14:43:41+05:30","dateModified":"2016-12-19T15:28:30+05:30"},{"@type":"WebSite","@id":"https:\/\/www.tothenew.com\/blog\/#website","url":"https:\/\/www.tothenew.com\/blog\/","name":"TO THE NEW Blog","inLanguage":"en-US","publisher":{"@id":"https:\/\/www.tothenew.com\/blog\/#organization"}}]},"og:locale":"en_US","og:site_name":"TO THE NEW BLOG","og:type":"blog","og:title":"Injecting Method to trim string length on gsp pages | TO THE NEW Blog","og:description":"Restricting the length of a string on gsps is a common scenario in most of our projects. Groovy's metaprogramming magic made it too simple for me. I added the following lines of code to Bootstrap.groovy: Object.metaClass.trimLength = {Integer stringLength -&gt; String trimString = delegate?.toString() String concatenateString = &quot;...&quot; List separators = [&quot;.&quot;, &quot; &quot;] if","og:url":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/","og:image":"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png","og:image:secure_url":"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png","twitter:card":"summary","twitter:site":"@tothenew","twitter:title":"Injecting Method to trim string length on gsp pages | TO THE NEW Blog","twitter:description":"Restricting the length of a string on gsps is a common scenario in most of our projects. Groovy's metaprogramming magic made it too simple for me. I added the following lines of code to Bootstrap.groovy: Object.metaClass.trimLength = {Integer stringLength -&gt; String trimString = delegate?.toString() String concatenateString = &quot;...&quot; List separators = [&quot;.&quot;, &quot; &quot;] if","twitter:image":"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png"},"aioseo_meta_data":{"post_id":"633","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":"Article","isEnabled":true},"graphs":[]},"schema_type":null,"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":"2021-04-30 08:16:02","updated":"2024-02-29 11:01:21","focus_keyword":null,"additional_keywords":null,"truseo_locale":null,"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.tothenew.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.tothenew.com\/blog\/category\/grails\/\" title=\"Grails\">Grails<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tInjecting Method to trim string length on gsp pages\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/www.tothenew.com\/blog"},{"label":"Grails","link":"https:\/\/www.tothenew.com\/blog\/category\/grails\/"},{"label":"Injecting Method to trim string length on gsp pages","link":"https:\/\/www.tothenew.com\/blog\/injecting-method-to-trim-string-length-on-gsp-pages\/"}],"_links":{"self":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts\/633","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/users\/282"}],"replies":[{"embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/comments?post=633"}],"version-history":[{"count":0,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts\/633\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/media?parent=633"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/categories?post=633"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/tags?post=633"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}