{"id":3380,"date":"2021-10-30T02:12:48","date_gmt":"2021-10-30T07:12:48","guid":{"rendered":"http:\/\/upmostlymulti.onpressidium.com\/?p=3380"},"modified":"2021-11-03T06:37:11","modified_gmt":"2021-11-03T11:37:11","slug":"using-react-inline-styles","status":"publish","type":"post","link":"http:\/\/upmostly.com\/tutorials\/using-react-inline-styles","title":{"rendered":"Using React Inline Styles"},"content":{"rendered":"\n<p>Styles are essential to any modern web page. They regulate the sizes, shapes, colors, and features of UI elements on-screen. <\/p>\n\n\n\n<p>While we can add styles in a CSS file (and then reference it in our React code), React gives us the option to add these styles directly into elements using inline styles. <\/p>\n\n\n\n<p>In this tutorial we&#8217;ll go over inline styles with React in JSX, which allow us to code in styles in a higher-level, more intuitive way. <\/p>\n\n\n\n<p>First, we&#8217;ll set up a standard web app using <strong><em>create-react-app<\/em><\/strong>. Then we&#8217;ll create a new file, called <strong><span class=\"has-inline-color has-vivid-red-color\">Element.js<\/span><\/strong>, and reference it in <strong><span class=\"has-inline-color has-vivid-red-color\">App.js<\/span><\/strong>:<\/p>\n\n\n\n<div class=\"wp-block-cgb-block-codeplus\"><div class=\"upmostly-block better-code-block\"><div class=\"dark\"><div class=\"code-editor-header\">Element.js<\/div><pre class=\"language-javascript\"><code class=\"language-javascript\"><div>\n<span class=\"token keyword\">function<\/span> <span class=\"token function\">Element<\/span><span class=\"token punctuation\">(<\/span> props <span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<\/span>\n    <span class=\"token keyword\">return<\/span><span class=\"token punctuation\">(<\/span>\n        <span class=\"token operator\">&lt;<\/span>div<span class=\"token operator\">><\/span>\n            <span class=\"token punctuation\">{<\/span>props<span class=\"token punctuation\">.<\/span>name<span class=\"token punctuation\">}<\/span>\n        <span class=\"token operator\">&lt;<\/span><span class=\"token operator\">\/<\/span>div<span class=\"token operator\">><\/span>\n    <span class=\"token punctuation\">)<\/span>\n<span class=\"token punctuation\">}<\/span>\n\n<span class=\"token keyword\">export<\/span> <span class=\"token punctuation\">{<\/span> Element <span class=\"token punctuation\">}<\/span>\n<\/div><\/code><\/pre><\/div><\/div><\/div>\n\n\n\n<p>Now, we&#8217;ll clear the boilerplate code in <strong><span class=\"has-inline-color has-vivid-red-color\">App.js<\/span><\/strong> and add a couple references to the <strong><em>Element <\/em><\/strong>we just created:<\/p>\n\n\n\n<div class=\"wp-block-cgb-block-codeplus\"><div class=\"upmostly-block better-code-block\"><div class=\"dark\"><div class=\"code-editor-header\">App.js<\/div><pre class=\"language-javascript\"><code class=\"language-javascript\"><div>\n<span class=\"token keyword\">import<\/span> <span class=\"token punctuation\">{<\/span> Element <span class=\"token punctuation\">}<\/span> <span class=\"token keyword\">from<\/span> <span class=\"token string\">'.\/Element'<\/span>\n\n<span class=\"token keyword\">function<\/span> <span class=\"token function\">App<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<\/span>\n  <span class=\"token keyword\">return<\/span> <span class=\"token punctuation\">(<\/span>\n    <span class=\"token operator\">&lt;<\/span>div<span class=\"token operator\">&gt;<\/span>\n      <span class=\"token operator\">&lt;<\/span>Element name<span class=\"token operator\">=<\/span><span class=\"token string\">\"Element 1\"<\/span><span class=\"token operator\">\/<\/span><span class=\"token operator\">&gt;<\/span>\n      <span class=\"token operator\">&lt;<\/span>Element name<span class=\"token operator\">=<\/span><span class=\"token string\">\"Element 2\"<\/span><span class=\"token operator\">\/<\/span><span class=\"token operator\">&gt;<\/span>\n    <span class=\"token operator\">&lt;<\/span><span class=\"token operator\">\/<\/span>div<span class=\"token operator\">&gt;<\/span>\n  <span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span>\n<span class=\"token punctuation\">}<\/span>\n\n<span class=\"token keyword\">export<\/span> <span class=\"token keyword\">default<\/span> App<span class=\"token punctuation\">;<\/span>\n<\/div><\/code><\/pre><\/div><\/div><\/div>\n\n\n\n<p>To completely clear any external styles, we&#8217;ll get rid of the CSS import in <strong><span class=\"has-inline-color has-vivid-red-color\">Index.js<\/span><\/strong>:<\/p>\n\n\n\n<div class=\"wp-block-cgb-block-codeplus\"><div class=\"upmostly-block better-code-block\"><div class=\"dark\"><div class=\"code-editor-header\">Index.js<\/div><pre class=\"language-javascript\"><code class=\"language-javascript\"><div>\n<span class=\"token keyword\">import<\/span> React <span class=\"token keyword\">from<\/span> <span class=\"token string\">'react'<\/span><span class=\"token punctuation\">;<\/span>\n<span class=\"token keyword\">import<\/span> ReactDOM <span class=\"token keyword\">from<\/span> <span class=\"token string\">'react-dom'<\/span><span class=\"token punctuation\">;<\/span>\n<span class=\"token keyword\">import<\/span> App <span class=\"token keyword\">from<\/span> <span class=\"token string\">'.\/App'<\/span><span class=\"token punctuation\">;<\/span>\n\nReactDOM<span class=\"token punctuation\">.<\/span><span class=\"token function\">render<\/span><span class=\"token punctuation\">(<\/span>\n  <span class=\"token operator\">&lt;<\/span>React<span class=\"token punctuation\">.<\/span>StrictMode<span class=\"token operator\">&gt;<\/span>\n    <span class=\"token operator\">&lt;<\/span>App <span class=\"token operator\">\/<\/span><span class=\"token operator\">&gt;<\/span>\n  <span class=\"token operator\">&lt;<\/span><span class=\"token operator\">\/<\/span>React<span class=\"token punctuation\">.<\/span>StrictMode<span class=\"token operator\">&gt;<\/span><span class=\"token punctuation\">,<\/span>\n  document<span class=\"token punctuation\">.<\/span><span class=\"token function\">getElementById<\/span><span class=\"token punctuation\">(<\/span><span class=\"token string\">'root'<\/span><span class=\"token punctuation\">)<\/span>\n<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span>\n<\/div><\/code><\/pre><\/div><\/div><\/div>\n\n\n\n<p>Now, when we run the code, we get the following web page in the browser:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"453\" height=\"274\" src=\"http:\/\/upmostly.com\/wp-content\/uploads\/Capture-61.png\" alt=\"\" class=\"wp-image-3381\" srcset=\"https:\/\/upmostly.com\/wp-content\/uploads\/Capture-61.png 453w, https:\/\/upmostly.com\/wp-content\/uploads\/Capture-61-300x181.png 300w\" sizes=\"auto, (max-width: 453px) 100vw, 453px\" \/><\/figure>\n\n\n\n<p>The elements are styled with HTML&#8217;s standard settings. We&#8217;ll now use inline styles to add a modern look. <\/p>\n\n\n\n<p>First, we&#8217;ll demonstrate how to use inline styles to change color. We&#8217;ll set the text color of all elements to red in <span class=\"has-inline-color has-vivid-red-color\"><strong>Element.js<\/strong><\/span>:<\/p>\n\n\n\n<div class=\"wp-block-cgb-block-codeplus\"><div class=\"upmostly-block better-code-block\"><div class=\"dark\"><div class=\"code-editor-header\">Element.js<\/div><pre class=\"language-javascript\"><code class=\"language-javascript\"><div>\n<span class=\"token keyword\">function<\/span> <span class=\"token function\">Element<\/span><span class=\"token punctuation\">(<\/span> props <span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<\/span>\n    <span class=\"token keyword\">return<\/span><span class=\"token punctuation\">(<\/span>\n        <span class=\"token operator\">&lt;<\/span>div style<span class=\"token operator\">=<\/span><span class=\"token punctuation\">{<\/span><span class=\"token punctuation\">{<\/span>color<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'red'<\/span><span class=\"token punctuation\">}<\/span><span class=\"token punctuation\">}<\/span><span class=\"token operator\">&gt;<\/span>\n            <span class=\"token punctuation\">{<\/span>props<span class=\"token punctuation\">.<\/span>name<span class=\"token punctuation\">}<\/span>\n        <span class=\"token operator\">&lt;<\/span><span class=\"token operator\">\/<\/span>div<span class=\"token operator\">&gt;<\/span>\n    <span class=\"token punctuation\">)<\/span>\n<span class=\"token punctuation\">}<\/span>\n\n<span class=\"token keyword\">export<\/span> <span class=\"token punctuation\">{<\/span> Element <span class=\"token punctuation\">}<\/span>\n<\/div><\/code><\/pre><\/div><\/div><\/div>\n\n\n\n<p>The result is:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"394\" height=\"189\" src=\"http:\/\/upmostly.com\/wp-content\/uploads\/Capture-62.png\" alt=\"\" class=\"wp-image-3384\" srcset=\"https:\/\/upmostly.com\/wp-content\/uploads\/Capture-62.png 394w, https:\/\/upmostly.com\/wp-content\/uploads\/Capture-62-300x144.png 300w\" sizes=\"auto, (max-width: 394px) 100vw, 394px\" \/><\/figure>\n\n\n\n<p>In the above code, we used the &#8220;style&#8221; attribute in the &lt;div&gt; JSX element to add inline styles. Then, we used a double curly brace before specifying the styles to use, which in this case was just a setting of color to red. <\/p>\n\n\n\n<p>The double braces are important, as each set of curly braces does something different. The outer set specifies that we are using a variable; since the return portion is written in JSX, our code won&#8217;t know that we are setting the attribute to a variable unless we use curly braces around it. <\/p>\n\n\n\n<p>The inner set of curly braces specifies a JavaScript object. JavaScript objects are mappings between keys and values; in this case, we are mapping the key color to the value &#8220;red&#8221;. <\/p>\n\n\n\n<p>Notice also that we applied the inline style to a JSX &lt;div&gt; rather than a JSX React element. The &#8220;style&#8221; attribute is a special attribute in React which applies only to HTML JSX tags. <\/p>\n\n\n\n<p>Now, let&#8217;s add a fuller set of styles to <strong><span class=\"has-inline-color has-vivid-red-color\">Element.js<\/span><\/strong>:<\/p>\n\n\n\n<div class=\"wp-block-cgb-block-codeplus\"><div class=\"upmostly-block better-code-block\"><div class=\"dark\"><div class=\"code-editor-header\">Element.js<\/div><pre class=\"language-javascript\"><code class=\"language-javascript\"><div>\n<span class=\"token keyword\">function<\/span> <span class=\"token function\">Element<\/span><span class=\"token punctuation\">(<\/span> props <span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<\/span>\n    <span class=\"token keyword\">return<\/span><span class=\"token punctuation\">(<\/span>\n        <span class=\"token operator\">&lt;<\/span>div style<span class=\"token operator\">=<\/span><span class=\"token punctuation\">{<\/span><span class=\"token punctuation\">{<\/span>\n            backgroundColor<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'gray'<\/span><span class=\"token punctuation\">,<\/span> \n            fontFamily<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'Arial, Helvetica, sans-serif'<\/span><span class=\"token punctuation\">,<\/span> \n            width<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'max-content'<\/span><span class=\"token punctuation\">,<\/span> \n            padding<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'10px'<\/span><span class=\"token punctuation\">,<\/span>\n            margin<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'5px'<\/span><span class=\"token punctuation\">,<\/span>\n            border<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'1px solid black'<\/span><span class=\"token punctuation\">,<\/span>\n            borderRadius<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'5px'<\/span>\n            <span class=\"token punctuation\">}<\/span><span class=\"token punctuation\">}<\/span><span class=\"token operator\">&gt;<\/span>\n            <span class=\"token punctuation\">{<\/span>props<span class=\"token punctuation\">.<\/span>name<span class=\"token punctuation\">}<\/span>\n        <span class=\"token operator\">&lt;<\/span><span class=\"token operator\">\/<\/span>div<span class=\"token operator\">&gt;<\/span>\n    <span class=\"token punctuation\">)<\/span>\n<span class=\"token punctuation\">}<\/span>\n\n<span class=\"token keyword\">export<\/span> <span class=\"token punctuation\">{<\/span> Element <span class=\"token punctuation\">}<\/span>\n<\/div><\/code><\/pre><\/div><\/div><\/div>\n\n\n\n<p>We get the following in our browser:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"375\" height=\"292\" src=\"http:\/\/upmostly.com\/wp-content\/uploads\/Capture-63.png\" alt=\"\" class=\"wp-image-3386\" srcset=\"https:\/\/upmostly.com\/wp-content\/uploads\/Capture-63.png 375w, https:\/\/upmostly.com\/wp-content\/uploads\/Capture-63-300x234.png 300w\" sizes=\"auto, (max-width: 375px) 100vw, 375px\" \/><\/figure>\n\n\n\n<p>The code structure is exactly the same, but with more styles within the double curly brace, separated from each other with commas.<\/p>\n\n\n\n<p>Notice how we put different styles on different lines, adding the newline after the comma. This is a good programming practice, allowing us to see clearly all the styles that are being applied. The alternative is to have a very long set of styles all on one line, which is not very legible. <\/p>\n\n\n\n<p>What if we wanted to be able to specify different background colors for our elements? Since we can&#8217;t use the style attribute directly on our React JSX elements, we have to use a workaround via props. <\/p>\n\n\n\n<p>First, we&#8217;ll add a new &#8220;backgroundColor&#8221; attribute in each of our elements in <strong><span class=\"has-inline-color has-vivid-red-color\">App.js<\/span><\/strong>:<\/p>\n\n\n\n<div class=\"wp-block-cgb-block-codeplus\"><div class=\"upmostly-block better-code-block\"><div class=\"dark\"><div class=\"code-editor-header\">App.js<\/div><pre class=\"language-javascript\"><code class=\"language-javascript\"><div>\n<span class=\"token keyword\">import<\/span> <span class=\"token punctuation\">{<\/span> Element <span class=\"token punctuation\">}<\/span> <span class=\"token keyword\">from<\/span> <span class=\"token string\">'.\/Element'<\/span>\n\n<span class=\"token keyword\">function<\/span> <span class=\"token function\">App<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<\/span>\n  <span class=\"token keyword\">return<\/span> <span class=\"token punctuation\">(<\/span>\n    <span class=\"token operator\">&lt;<\/span>div<span class=\"token operator\">&gt;<\/span>\n      <span class=\"token operator\">&lt;<\/span>Element name<span class=\"token operator\">=<\/span><span class=\"token string\">\"Element 1\"<\/span> backgroundColor<span class=\"token operator\">=<\/span><span class=\"token string\">\"red\"<\/span><span class=\"token operator\">\/<\/span><span class=\"token operator\">&gt;<\/span>\n      <span class=\"token operator\">&lt;<\/span>Element name<span class=\"token operator\">=<\/span><span class=\"token string\">\"Element 2\"<\/span> backgroundColor<span class=\"token operator\">=<\/span><span class=\"token string\">\"green\"<\/span><span class=\"token operator\">\/<\/span><span class=\"token operator\">&gt;<\/span>\n      <span class=\"token operator\">&lt;<\/span>Element name<span class=\"token operator\">=<\/span><span class=\"token string\">\"Element 3\"<\/span><span class=\"token operator\">\/<\/span><span class=\"token operator\">&gt;<\/span>\n    <span class=\"token operator\">&lt;<\/span><span class=\"token operator\">\/<\/span>div<span class=\"token operator\">&gt;<\/span>\n  <span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span>\n<span class=\"token punctuation\">}<\/span>\n\n<span class=\"token keyword\">export<\/span> <span class=\"token keyword\">default<\/span> App<span class=\"token punctuation\">;<\/span>\n<\/div><\/code><\/pre><\/div><\/div><\/div>\n\n\n\n<p>Now, we&#8217;ll rewrite <strong><span class=\"has-inline-color has-vivid-red-color\">Element.js<\/span><\/strong> to utilize the new attribute via props:<\/p>\n\n\n\n<div class=\"wp-block-cgb-block-codeplus\"><div class=\"upmostly-block better-code-block\"><div class=\"dark\"><div class=\"code-editor-header\">Element.js<\/div><pre class=\"language-javascript\"><code class=\"language-javascript\"><div>\n<span class=\"token keyword\">function<\/span> <span class=\"token function\">Element<\/span><span class=\"token punctuation\">(<\/span> props <span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<\/span>\n\n    <span class=\"token keyword\">var<\/span> backgroundColor<span class=\"token punctuation\">;<\/span>\n    <span class=\"token keyword\">if<\/span> <span class=\"token punctuation\">(<\/span> props<span class=\"token punctuation\">.<\/span>backgroundColor <span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<\/span>\n        backgroundColor <span class=\"token operator\">=<\/span> props<span class=\"token punctuation\">.<\/span>backgroundColor<span class=\"token punctuation\">;<\/span>\n    <span class=\"token punctuation\">}<\/span> <span class=\"token keyword\">else<\/span> <span class=\"token punctuation\">{<\/span>\n        backgroundColor <span class=\"token operator\">=<\/span> <span class=\"token string\">'gray'<\/span><span class=\"token punctuation\">;<\/span>\n    <span class=\"token punctuation\">}<\/span>\n\n    <span class=\"token keyword\">return<\/span><span class=\"token punctuation\">(<\/span>\n        <span class=\"token operator\">&lt;<\/span>div style<span class=\"token operator\">=<\/span><span class=\"token punctuation\">{<\/span><span class=\"token punctuation\">{<\/span>\n            backgroundColor<span class=\"token punctuation\">:<\/span> backgroundColor<span class=\"token punctuation\">,<\/span> \n            fontFamily<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'Arial, Helvetica, sans-serif'<\/span><span class=\"token punctuation\">,<\/span> \n            width<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'max-content'<\/span><span class=\"token punctuation\">,<\/span> \n            padding<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'10px'<\/span><span class=\"token punctuation\">,<\/span>\n            margin<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'5px'<\/span><span class=\"token punctuation\">,<\/span>\n            border<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'1px solid black'<\/span><span class=\"token punctuation\">,<\/span>\n            borderRadius<span class=\"token punctuation\">:<\/span> <span class=\"token string\">'5px'<\/span>\n            <span class=\"token punctuation\">}<\/span><span class=\"token punctuation\">}<\/span><span class=\"token operator\">&gt;<\/span>\n            <span class=\"token punctuation\">{<\/span>props<span class=\"token punctuation\">.<\/span>name<span class=\"token punctuation\">}<\/span>\n        <span class=\"token operator\">&lt;<\/span><span class=\"token operator\">\/<\/span>div<span class=\"token operator\">&gt;<\/span>\n    <span class=\"token punctuation\">)<\/span>\n<span class=\"token punctuation\">}<\/span>\n\n<span class=\"token keyword\">export<\/span> <span class=\"token punctuation\">{<\/span> Element <span class=\"token punctuation\">}<\/span>\n<\/div><\/code><\/pre><\/div><\/div><\/div>\n\n\n\n<p>In the above code, we add an if\/else statement that will try to use &#8220;props.backgroundColor&#8221; to set the variable &#8220;backgroundColor&#8221;. If there is no &#8220;props.backgroundColor&#8221;, the value of &#8220;backgroundColor&#8221; defaults to &#8220;gray&#8221;. <\/p>\n\n\n\n<p>Then, we set the &#8220;backgroundColor&#8221; style in our return statement to the variable &#8220;backgroundColor&#8221;. Notice that we don&#8217;t have to add curly braces to it this time around, since the set of curly braces that we added before wraps around our variable reference. <\/p>\n\n\n\n<p>We get the following output in our browser:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"482\" height=\"341\" src=\"http:\/\/upmostly.com\/wp-content\/uploads\/Capture-64.png\" alt=\"\" class=\"wp-image-3387\" srcset=\"https:\/\/upmostly.com\/wp-content\/uploads\/Capture-64.png 482w, https:\/\/upmostly.com\/wp-content\/uploads\/Capture-64-300x212.png 300w\" sizes=\"auto, (max-width: 482px) 100vw, 482px\" \/><\/figure>\n\n\n\n<p>Now we can set the colors of specific elements!<\/p>\n\n\n\n<p>And that&#8217;s it! Have fun using React&#8217;s inline styling!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Styles are essential to any modern web page. They regulate the sizes, shapes, colors, and features of UI elements on-screen. While we can add styles in a CSS file (and then reference it in our React code), React gives us the option to add these styles directly into elements using inline styles. In this tutorial [&hellip;]<\/p>\n","protected":false},"author":14,"featured_media":3780,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1],"tags":[33,4],"class_list":["post-3380","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tutorials","tag-beginner-react-tutorials","tag-react"],"acf":[],"_links":{"self":[{"href":"https:\/\/upmostly.com\/wp-json\/wp\/v2\/posts\/3380","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/upmostly.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/upmostly.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/upmostly.com\/wp-json\/wp\/v2\/users\/14"}],"replies":[{"embeddable":true,"href":"https:\/\/upmostly.com\/wp-json\/wp\/v2\/comments?post=3380"}],"version-history":[{"count":5,"href":"https:\/\/upmostly.com\/wp-json\/wp\/v2\/posts\/3380\/revisions"}],"predecessor-version":[{"id":3783,"href":"https:\/\/upmostly.com\/wp-json\/wp\/v2\/posts\/3380\/revisions\/3783"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/upmostly.com\/wp-json\/wp\/v2\/media\/3780"}],"wp:attachment":[{"href":"https:\/\/upmostly.com\/wp-json\/wp\/v2\/media?parent=3380"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/upmostly.com\/wp-json\/wp\/v2\/categories?post=3380"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/upmostly.com\/wp-json\/wp\/v2\/tags?post=3380"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}