{"id":28181,"date":"2022-04-25T06:34:25","date_gmt":"2022-04-25T06:34:25","guid":{"rendered":"http:\/\/how-to-add-fx-to-images-before-uploading"},"modified":"2022-04-25T06:34:25","modified_gmt":"2022-04-25T06:34:25","slug":"how-to-add-fx-to-images-before-uploading","status":"publish","type":"post","link":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/","title":{"rendered":"How to Add FX to Images before Uploading"},"content":{"rendered":"<div class=\"wp-block-cloudinary-markdown \"><p>Excellent and unique aesthetics make it easy to distinguish on social networking sites, especially in today\u2019s image-driven environment.<\/p>\n<p>Your image will be more appealing with effects, and it will undoubtedly enhance your imagination.<\/p>\n<p>An image is a universal language that transcends all barriers. It can communicate effectively with anyone, and it will be even more effective if it has a more pleasing appearance.<\/p>\n<p>This article will show you how to add FX to images before uploading.<\/p>\n<p>The completed project is on <a href=\"https:\/\/codesandbox.io\/s\/wizardly-sound-oe8qz9?file=\/src\/App.js\">Codesandbox<\/a>.<\/p>\n<h1>Prerequisite<\/h1>\n<p>The knowledge of JavaScript and React.js is required to follow through with this article. Also, you need to ensure that you have <a href=\"https:\/\/nodejs.org\/en\/\">Node.js<\/a> and npm installed to follow along.<\/p>\n<p>To Verify the node version installed,  use the following terminal command:<\/p>\n<pre class=\"js-syntax-highlighted\"><span><code class=\"hljs shcb-wrap-lines\">node -v &amp;&amp; npm -v \n<\/code><\/span><\/pre>\n<p>The above command should output their respective versions if installed.<\/p>\n<h2>Project Setup<\/h2>\n<p>To create a new project, use the <code>npx create-react-app &lt;project name&gt;<\/code> command to scaffold a new project in a directory of your choice.<\/p>\n<p>To install the dependencies, you should use the command below:<\/p>\n<pre class=\"js-syntax-highlighted\" aria-describedby=\"shcb-language-1\" data-shcb-language-name=\"HTML, XML\" data-shcb-language-slug=\"xml\"><span><code class=\"hljs language-xml shcb-wrap-lines\">cd <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">project<\/span> <span class=\"hljs-attr\">name<\/span>&gt;<\/span>\nnpm install lena.js\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-1\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">HTML, XML<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">xml<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n<p>Once the app is created, and the dependencies are installed, you will see a message with instructions for navigating to your site and running it locally. You can do this with the following command.<\/p>\n<pre class=\"js-syntax-highlighted\"><span><code class=\"hljs shcb-wrap-lines\">npm start\n<\/code><\/span><\/pre>\n<p>React.js will start a hot-reloading development environment accessible by default at <a href=\"http:\/\/localhost:3000\">http:\/\/localhost:3000<\/a>.<\/p>\n<p>Next, update the <code>src\/App.js<\/code> file with the code snippet below.<\/p>\n<pre class=\"js-syntax-highlighted\" aria-describedby=\"shcb-language-2\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\"><span class=\"hljs-keyword\">import<\/span> { useEffect, useRef, useState } <span class=\"hljs-keyword\">from<\/span> <span class=\"hljs-string\">\"react\"<\/span>;\n<span class=\"hljs-keyword\">import<\/span> <span class=\"hljs-string\">\".\/styles.css\"<\/span>;\n    \n<span class=\"hljs-keyword\">export<\/span> <span class=\"hljs-keyword\">default<\/span> <span class=\"hljs-function\"><span class=\"hljs-keyword\">function<\/span> <span class=\"hljs-title\">App<\/span>(<span class=\"hljs-params\"><\/span>) <\/span>{\n    \n<span class=\"hljs-keyword\">return<\/span> (\n  <span class=\"xml\"><span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"App\"<\/span>&gt;<\/span>\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">h1<\/span>&gt;<\/span>How to add FX to images before uploading<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">h1<\/span>&gt;<\/span>\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"splitdiv\"<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"leftdiv\"<\/span>&gt;<\/span>\n      <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"leftdivcard\"<\/span>&gt;<\/span>\n        <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">h1<\/span>&gt;<\/span>Select your favourite FX<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">h1<\/span>&gt;<\/span>\n      <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span>\n    <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span>\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"splitdiv\"<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"rightdiv\"<\/span>&gt;<\/span>\n    <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span>\n  <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span><\/span>\n);\n}\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-2\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n<p>The current user interface doesn\u2019t look aesthetically pleasing, so you need to add some styling with CSS. You can update <code>src\/styles.css<\/code> file with the following content in this <a href=\"https:\/\/gist.github.com\/Olanetsoft\/c3a7da55bd7721c72c2718726e1008ad\">GitHub Gist<\/a>.<\/p>\n<p>After adding the styling, your application should look like the image below.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/cloudinary-marketing-res.cloudinary.com\/image\/upload\/c_limit,w_2000\/f_auto\/q_auto\/media_jams\/s_7F7E71A397FE57F69714E23550BBBDB1F3A98FA2A79DC9059C08749E1331C34C_1649543992169_Screenshot+2022-04-09+at+23.35.35.png\" alt=\"How to add FX to images before uploading\" loading=\"lazy\" class=\"c-transformed-asset\"  width=\"2000\" height=\"1116\"\/><\/p>\n<h2>Adding Effects to Image<\/h2>\n<p>This section will render a default image which  will be us add an effect in the following section.<\/p>\n<p>Replace your return function with the code snippet below to render a default image.<\/p>\n<pre class=\"js-syntax-highlighted\" aria-describedby=\"shcb-language-3\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\">    <span class=\"hljs-comment\">\/\/...   <\/span>\n<span class=\"hljs-keyword\">return<\/span> (\n<span class=\"xml\"><span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"App\"<\/span>&gt;<\/span>\n    \/\/...\n<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"splitdiv\"<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"rightdiv\"<\/span>&gt;<\/span>\n  <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"itemdivcard\"<\/span>&gt;<\/span>\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">img<\/span>\n      <span class=\"hljs-attr\">style<\/span>=<span class=\"hljs-string\">{{<\/span> <span class=\"hljs-attr\">height:<\/span> \"<span class=\"hljs-attr\">50<\/span>%\" }}\n      <span class=\"hljs-attr\">crossOrigin<\/span>=<span class=\"hljs-string\">\"anonymous\"<\/span>\n      <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"original-image\"<\/span>\n      <span class=\"hljs-attr\">src<\/span>=<span class=\"hljs-string\">\"https:\/\/res.cloudinary.com\/olanetsoft\/image\/upload\/v1649599954\/uploadedFiles\/family-picture.jpg\"<\/span>\n      <span class=\"hljs-attr\">alt<\/span>=<span class=\"hljs-string\">\"Original\"<\/span>\n      \/&gt;<\/span>\n  <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span>\n<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span>\n<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span><\/span>\n);\n}\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-3\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n<p>Your application should look like the image below.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/cloudinary-marketing-res.cloudinary.com\/image\/upload\/c_limit,w_2000\/f_auto\/q_auto\/media_jams\/s_7F7E71A397FE57F69714E23550BBBDB1F3A98FA2A79DC9059C08749E1331C34C_1649600026893_Screenshot+2022-04-10+at+15.13.08.png\" alt=\"How to add FX to images before uploading\" loading=\"lazy\" class=\"c-transformed-asset\"  width=\"2000\" height=\"1117\"\/><\/p>\n<p>Import the lena.js dependency<\/p>\n<pre class=\"js-syntax-highlighted\" aria-describedby=\"shcb-language-4\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\"><span class=\"hljs-keyword\">import<\/span> { useEffect, useRef, useState } <span class=\"hljs-keyword\">from<\/span> <span class=\"hljs-string\">\"react\"<\/span>;\n<span class=\"hljs-keyword\">import<\/span> {\n  filterImage,\n  red <span class=\"hljs-keyword\">as<\/span> lenaRed,\n  blue <span class=\"hljs-keyword\">as<\/span> lenaBlue,\n  green <span class=\"hljs-keyword\">as<\/span> lenaGreen,\n  canny <span class=\"hljs-keyword\">as<\/span> lenaCanny,\n  grayscale <span class=\"hljs-keyword\">as<\/span> lenaGrayscale,\n  invert <span class=\"hljs-keyword\">as<\/span> lenaInvert,\n  sepia <span class=\"hljs-keyword\">as<\/span> lenaSepia,\n  noise <span class=\"hljs-keyword\">as<\/span> lenaNoise,\n  saturation <span class=\"hljs-keyword\">as<\/span> lenaSaturation,\n  sobelHorizontal <span class=\"hljs-keyword\">as<\/span> lenaSobelHorizontal,\n  sobelVertical <span class=\"hljs-keyword\">as<\/span> lenaSobelVertical,\n  sharpen <span class=\"hljs-keyword\">as<\/span> lenaSharpen,\n  mirror <span class=\"hljs-keyword\">as<\/span> lenaMirror\n} <span class=\"hljs-keyword\">from<\/span> <span class=\"hljs-string\">\"lena.js\"<\/span>;\n    \n<span class=\"hljs-keyword\">export<\/span> <span class=\"hljs-keyword\">default<\/span> <span class=\"hljs-function\"><span class=\"hljs-keyword\">function<\/span> <span class=\"hljs-title\">App<\/span>(<span class=\"hljs-params\"><\/span>) <\/span>{\n  <span class=\"hljs-comment\">\/\/...<\/span>\n}\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-4\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n<p>Declare state variable <code>filter<\/code> with a <code>red<\/code>, a variable <code>originalRef<\/code> using a <code>useRef<\/code> with a default value of <code>null<\/code>, and <code>filteredRef<\/code> with a default <code>null<\/code> value, respectively.<\/p>\n<pre class=\"js-syntax-highlighted\" aria-describedby=\"shcb-language-5\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/...<\/span>\n\n<span class=\"hljs-keyword\">export<\/span> <span class=\"hljs-keyword\">default<\/span> <span class=\"hljs-function\"><span class=\"hljs-keyword\">function<\/span> <span class=\"hljs-title\">App<\/span>(<span class=\"hljs-params\"><\/span>) <\/span>{\n<span class=\"hljs-keyword\">const<\/span> originalRef = useRef(<span class=\"hljs-literal\">null<\/span>);\n<span class=\"hljs-keyword\">const<\/span> filteredRef = useRef(<span class=\"hljs-literal\">null<\/span>);\n<span class=\"hljs-keyword\">const<\/span> &#91;filter, setFilter] = useState(<span class=\"hljs-string\">\"red\"<\/span>);\n    \n<span class=\"hljs-keyword\">return<\/span> (\n    <span class=\"hljs-comment\">\/\/...<\/span>\n);\n}\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-5\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n<h2>Add filter to image<\/h2>\n<p>This section will show you how to add FX to the default image.<\/p>\n<p>First, Create a <code>Filter<\/code> object as this will  determine the filter color.<\/p>\n<pre class=\"js-syntax-highlighted\" aria-describedby=\"shcb-language-6\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/..<\/span>\n\n<span class=\"hljs-keyword\">export<\/span> <span class=\"hljs-keyword\">default<\/span> <span class=\"hljs-function\"><span class=\"hljs-keyword\">function<\/span> <span class=\"hljs-title\">App<\/span>(<span class=\"hljs-params\"><\/span>) <\/span>{\n<span class=\"hljs-comment\">\/\/...<\/span>\n    \n<span class=\"hljs-keyword\">const<\/span> filters = {\n  <span class=\"hljs-attr\">red<\/span>: lenaRed,\n  <span class=\"hljs-attr\">blue<\/span>: lenaBlue,\n  <span class=\"hljs-attr\">green<\/span>: lenaGreen,\n  <span class=\"hljs-attr\">canny<\/span>: lenaCanny,\n  <span class=\"hljs-attr\">grayscale<\/span>: lenaGrayscale,\n  <span class=\"hljs-attr\">invert<\/span>: lenaInvert,\n  <span class=\"hljs-attr\">sepia<\/span>: lenaSepia,\n  <span class=\"hljs-attr\">noise<\/span>: lenaNoise,\n  <span class=\"hljs-attr\">saturation<\/span>: lenaSaturation,\n  <span class=\"hljs-attr\">sobelHorizontal<\/span>: lenaSobelHorizontal,\n  <span class=\"hljs-attr\">sobelVertical<\/span>: lenaSobelVertical,\n  <span class=\"hljs-attr\">sharpen<\/span>: lenaSharpen,\n  <span class=\"hljs-attr\">mirror<\/span>: lenaMirror\n};\n     \n<span class=\"hljs-keyword\">return<\/span> (\n    <span class=\"hljs-comment\">\/\/...<\/span>\n);\n}\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-6\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n<p>Add a dropdown to change filters and create an <code>OnChange<\/code> function to track the changes.<\/p>\n<pre class=\"js-syntax-highlighted\" aria-describedby=\"shcb-language-7\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/..<\/span>\n    \n<span class=\"hljs-keyword\">export<\/span> <span class=\"hljs-keyword\">default<\/span> <span class=\"hljs-function\"><span class=\"hljs-keyword\">function<\/span> <span class=\"hljs-title\">App<\/span>(<span class=\"hljs-params\"><\/span>) <\/span>{\n<span class=\"hljs-comment\">\/\/...<\/span>\n    \n<span class=\"hljs-keyword\">const<\/span> OnChange = <span class=\"hljs-function\">(<span class=\"hljs-params\">e<\/span>) =&gt;<\/span> {\n  setFilter(e.target.value);\n};\n    \n<span class=\"hljs-keyword\">return<\/span> (\n  <span class=\"xml\"><span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"App\"<\/span>&gt;<\/span>\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">h1<\/span>&gt;<\/span>How to add FX to images before uploading<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">h1<\/span>&gt;<\/span>\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"splitdiv\"<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"leftdiv\"<\/span>&gt;<\/span>\n      <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"leftdivcard\"<\/span>&gt;<\/span>\n        <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">h1<\/span>&gt;<\/span>Select your favourite FX<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">h1<\/span>&gt;<\/span>\n        <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">select<\/span>\n        <span class=\"hljs-attr\">name<\/span>=<span class=\"hljs-string\">\"membership\"<\/span>\n        <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"membership\"<\/span>\n        <span class=\"hljs-attr\">value<\/span>=<span class=\"hljs-string\">{filter}<\/span>\n        <span class=\"hljs-attr\">onChange<\/span>=<span class=\"hljs-string\">{OnChange}<\/span>\n        &gt;<\/span>\n          {Object.keys(filters).map((key) =&gt; (\n            <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">option<\/span> <span class=\"hljs-attr\">key<\/span>=<span class=\"hljs-string\">{key}<\/span> <span class=\"hljs-attr\">value<\/span>=<span class=\"hljs-string\">{key}<\/span>&gt;<\/span>\n              {key}\n            <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">option<\/span>&gt;<\/span>\n          ))}\n        <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">select<\/span>&gt;<\/span>\n      <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span>\n    <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span>\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"splitdiv\"<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"rightdiv\"<\/span>&gt;<\/span>\n       \/\/...\n    <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span>\n  <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span><\/span>\n);\n}\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-7\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n<p>Next, add a <code>useEffect<\/code> to track the <code>originalRef<\/code> onload and render the canvas for the filter.<\/p>\n<pre class=\"js-syntax-highlighted\" aria-describedby=\"shcb-language-8\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/...<\/span>\n    \n<span class=\"hljs-keyword\">export<\/span> <span class=\"hljs-keyword\">default<\/span> <span class=\"hljs-function\"><span class=\"hljs-keyword\">function<\/span> <span class=\"hljs-title\">App<\/span>(<span class=\"hljs-params\"><\/span>) <\/span>{\n  <span class=\"hljs-comment\">\/\/...<\/span>\n    \nuseEffect(<span class=\"hljs-function\"><span class=\"hljs-params\">()<\/span> =&gt;<\/span> {\n  originalRef.current.onload = <span class=\"hljs-function\"><span class=\"hljs-params\">()<\/span> =&gt;<\/span> {\n    filterImage(filteredRef.current, filters&#91;filter], originalRef.current);\n  };\n});\n    \n<span class=\"hljs-keyword\">return<\/span> (\n  <span class=\"xml\"><span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"App\"<\/span>&gt;<\/span>\n    \/\/...\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"splitdiv\"<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"rightdiv\"<\/span>&gt;<\/span>\n      \/\/...\n      <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"itemdivcard\"<\/span>&gt;<\/span>\n        {filteredRef &amp;&amp; (\n          <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">canvas<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"filtered-image\"<\/span> <span class=\"hljs-attr\">ref<\/span>=<span class=\"hljs-string\">{filteredRef}<\/span>&gt;<\/span><span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">canvas<\/span>&gt;<\/span>\n        )}\n      <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span> \n    <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span>\n  <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span><\/span>\n);\n}\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-8\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n<p>Update the image tag by adding a <code>ref<\/code> attribute.<\/p>\n<pre class=\"js-syntax-highlighted\" aria-describedby=\"shcb-language-9\" data-shcb-language-name=\"HTML, XML\" data-shcb-language-slug=\"xml\"><span><code class=\"hljs language-xml shcb-wrap-lines\"><span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"splitdiv\"<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"rightdiv\"<\/span>&gt;<\/span>\n  <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">id<\/span>=<span class=\"hljs-string\">\"itemdivcard\"<\/span>&gt;<\/span>\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">img<\/span>\n    \/\/<span class=\"hljs-attr\">...<\/span>\n    <span class=\"hljs-attr\">ref<\/span>=<span class=\"hljs-string\">{originalRef}<\/span>\n    \/&gt;<\/span>\n  <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span>\n      \/\/...\n<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span>\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-9\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">HTML, XML<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">xml<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n<p>You should have something similar to what is shown below.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/cloudinary-marketing-res.cloudinary.com\/image\/upload\/c_limit,w_2000\/f_auto\/q_auto\/media_jams\/s_7F7E71A397FE57F69714E23550BBBDB1F3A98FA2A79DC9059C08749E1331C34C_1649602309498_Screenshot+2022-04-10+at+15.51.19.png\" alt=\"How to add FX to images before uploading\" loading=\"lazy\" class=\"c-transformed-asset\"  width=\"2000\" height=\"1120\"\/><\/p>\n<p>If you notice, nothing happens when we change FX from the dropdown. We need to find a way to ensure the <code>useEffect<\/code> hook does not run on the initial render using <a href=\"https:\/\/reactjs.org\/docs\/hooks-custom.html\">custom hooks<\/a>.<\/p>\n<p>To achieve this, add the following code snippet.<\/p>\n<pre class=\"js-syntax-highlighted\" aria-describedby=\"shcb-language-10\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/...<\/span>\n    \n<span class=\"hljs-keyword\">export<\/span> <span class=\"hljs-keyword\">default<\/span> <span class=\"hljs-function\"><span class=\"hljs-keyword\">function<\/span> <span class=\"hljs-title\">App<\/span>(<span class=\"hljs-params\"><\/span>) <\/span>{\n  <span class=\"hljs-comment\">\/\/...<\/span>\n<span class=\"hljs-keyword\">const<\/span> didMount = useRef(<span class=\"hljs-literal\">false<\/span>);\n  <span class=\"hljs-comment\">\/\/...<\/span>\nuseEffect(<span class=\"hljs-function\"><span class=\"hljs-params\">()<\/span> =&gt;<\/span> {\n  <span class=\"hljs-keyword\">if<\/span> (didMount.current) {\n    filterImage(filteredRef.current, filters&#91;filter], originalRef.current);\n  } <span class=\"hljs-keyword\">else<\/span> {\n    didMount.current = <span class=\"hljs-literal\">true<\/span>;\n  }\n}, &#91;filter]);\n      \n<span class=\"hljs-keyword\">return<\/span> (\n  <span class=\"xml\"><span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div<\/span> <span class=\"hljs-attr\">className<\/span>=<span class=\"hljs-string\">\"App\"<\/span>&gt;<\/span>\n    \/\/...\n  <span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">div<\/span>&gt;<\/span><\/span>\n);\n}\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-10\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n<p>Testing the application, you should have everything working as expected, as shown below.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/cloudinary-marketing-res.cloudinary.com\/image\/upload\/c_limit,w_2000\/f_auto\/q_auto\/media_jams\/s_7F7E71A397FE57F69714E23550BBBDB1F3A98FA2A79DC9059C08749E1331C34C_1649602853348_Screenshot+2022-04-10+at+16.00.08.png\" alt=\"How to add FX to images before uploading\" loading=\"lazy\" class=\"c-transformed-asset\"  width=\"2000\" height=\"1115\"\/>\n<img decoding=\"async\" src=\"https:\/\/cloudinary-marketing-res.cloudinary.com\/image\/upload\/c_limit,w_2000\/f_auto\/q_auto\/media_jams\/s_7F7E71A397FE57F69714E23550BBBDB1F3A98FA2A79DC9059C08749E1331C34C_1649602853548_Screenshot+2022-04-10+at+16.00.30.png\" alt=\"How to add FX to images before uploading\" loading=\"lazy\" class=\"c-transformed-asset\"  width=\"2000\" height=\"1116\"\/><\/p>\n<p><img decoding=\"async\" src=\"https:\/\/cloudinary-marketing-res.cloudinary.com\/image\/upload\/c_limit,w_2000\/f_auto\/q_auto\/media_jams\/s_7F7E71A397FE57F69714E23550BBBDB1F3A98FA2A79DC9059C08749E1331C34C_1649602853189_Screenshot+2022-04-10+at+15.59.53.png\" alt=\"How to add FX to images before uploading\" loading=\"lazy\" class=\"c-transformed-asset\"  width=\"2000\" height=\"1116\"\/><\/p>\n<h2>Conclusion<\/h2>\n<p>This article explained how to add FX to images before uploading using lena.js.<\/p>\n<h2>Reference<\/h2>\n<ul>\n<li>\n<a href=\"https:\/\/www.npmjs.com\/package\/lena.js\/v\/0.7.6\">Lena<\/a>\n<\/li>\n<li>\n<a href=\"https:\/\/reactjs.org\/docs\/hooks-custom.html\">Custom Hooks<\/a>\n<\/li>\n<\/ul>\n<\/div>","protected":false},"excerpt":{"rendered":"","protected":false},"author":41,"featured_media":28182,"comment_status":"","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_cloudinary_featured_overwrite":false,"footnotes":""},"categories":[1],"tags":[134,370,177,246,371],"class_list":["post-28181","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-uncategorized","tag-guest-post","tag-image","tag-javascript","tag-react","tag-under-review"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v25.6 (Yoast SEO v26.9) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>How to Add FX to Images before Uploading<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Add FX to Images before Uploading\" \/>\n<meta property=\"og:url\" content=\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/\" \/>\n<meta property=\"og:site_name\" content=\"Cloudinary Blog\" \/>\n<meta property=\"article:published_time\" content=\"2022-04-25T06:34:25+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"NewsArticle\",\"@id\":\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/\"},\"author\":{\"name\":\"\",\"@id\":\"\"},\"headline\":\"How to Add FX to Images before Uploading\",\"datePublished\":\"2022-04-25T06:34:25+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/\"},\"wordCount\":8,\"publisher\":{\"@id\":\"https:\/\/cloudinary.com\/blog\/#organization\"},\"image\":{\"@id\":\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1681925193\/Web_Assets\/blog\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905.png?_i=AA\",\"keywords\":[\"Guest Post\",\"Image\",\"Javascript\",\"React\",\"Under Review\"],\"inLanguage\":\"en-US\",\"copyrightYear\":\"2022\",\"copyrightHolder\":{\"@id\":\"https:\/\/cloudinary.com\/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/\",\"url\":\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/\",\"name\":\"How to Add FX to Images before Uploading\",\"isPartOf\":{\"@id\":\"https:\/\/cloudinary.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1681925193\/Web_Assets\/blog\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905.png?_i=AA\",\"datePublished\":\"2022-04-25T06:34:25+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#primaryimage\",\"url\":\"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1681925193\/Web_Assets\/blog\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905.png?_i=AA\",\"contentUrl\":\"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1681925193\/Web_Assets\/blog\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905.png?_i=AA\",\"width\":1600,\"height\":893},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/cloudinary.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Add FX to Images before Uploading\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/cloudinary.com\/blog\/#website\",\"url\":\"https:\/\/cloudinary.com\/blog\/\",\"name\":\"Cloudinary Blog\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/cloudinary.com\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/cloudinary.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/cloudinary.com\/blog\/#organization\",\"name\":\"Cloudinary Blog\",\"url\":\"https:\/\/cloudinary.com\/blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/cloudinary.com\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1649718331\/Web_Assets\/blog\/cloudinary_logo_for_white_bg_1937437aa7_19374666c7_193742f877\/cloudinary_logo_for_white_bg_1937437aa7_19374666c7_193742f877.png?_i=AA\",\"contentUrl\":\"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1649718331\/Web_Assets\/blog\/cloudinary_logo_for_white_bg_1937437aa7_19374666c7_193742f877\/cloudinary_logo_for_white_bg_1937437aa7_19374666c7_193742f877.png?_i=AA\",\"width\":312,\"height\":60,\"caption\":\"Cloudinary Blog\"},\"image\":{\"@id\":\"https:\/\/cloudinary.com\/blog\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"How to Add FX to Images before Uploading","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/","og_locale":"en_US","og_type":"article","og_title":"How to Add FX to Images before Uploading","og_url":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/","og_site_name":"Cloudinary Blog","article_published_time":"2022-04-25T06:34:25+00:00","twitter_card":"summary_large_image","schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"NewsArticle","@id":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#article","isPartOf":{"@id":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/"},"author":{"name":"","@id":""},"headline":"How to Add FX to Images before Uploading","datePublished":"2022-04-25T06:34:25+00:00","mainEntityOfPage":{"@id":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/"},"wordCount":8,"publisher":{"@id":"https:\/\/cloudinary.com\/blog\/#organization"},"image":{"@id":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#primaryimage"},"thumbnailUrl":"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1681925193\/Web_Assets\/blog\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905.png?_i=AA","keywords":["Guest Post","Image","Javascript","React","Under Review"],"inLanguage":"en-US","copyrightYear":"2022","copyrightHolder":{"@id":"https:\/\/cloudinary.com\/#organization"}},{"@type":"WebPage","@id":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/","url":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/","name":"How to Add FX to Images before Uploading","isPartOf":{"@id":"https:\/\/cloudinary.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#primaryimage"},"image":{"@id":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#primaryimage"},"thumbnailUrl":"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1681925193\/Web_Assets\/blog\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905.png?_i=AA","datePublished":"2022-04-25T06:34:25+00:00","breadcrumb":{"@id":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#primaryimage","url":"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1681925193\/Web_Assets\/blog\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905.png?_i=AA","contentUrl":"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1681925193\/Web_Assets\/blog\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905.png?_i=AA","width":1600,"height":893},{"@type":"BreadcrumbList","@id":"https:\/\/cloudinary.com\/blog\/guest_post\/how-to-add-fx-to-images-before-uploading\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/cloudinary.com\/blog\/"},{"@type":"ListItem","position":2,"name":"How to Add FX to Images before Uploading"}]},{"@type":"WebSite","@id":"https:\/\/cloudinary.com\/blog\/#website","url":"https:\/\/cloudinary.com\/blog\/","name":"Cloudinary Blog","description":"","publisher":{"@id":"https:\/\/cloudinary.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/cloudinary.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/cloudinary.com\/blog\/#organization","name":"Cloudinary Blog","url":"https:\/\/cloudinary.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/cloudinary.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1649718331\/Web_Assets\/blog\/cloudinary_logo_for_white_bg_1937437aa7_19374666c7_193742f877\/cloudinary_logo_for_white_bg_1937437aa7_19374666c7_193742f877.png?_i=AA","contentUrl":"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1649718331\/Web_Assets\/blog\/cloudinary_logo_for_white_bg_1937437aa7_19374666c7_193742f877\/cloudinary_logo_for_white_bg_1937437aa7_19374666c7_193742f877.png?_i=AA","width":312,"height":60,"caption":"Cloudinary Blog"},"image":{"@id":"https:\/\/cloudinary.com\/blog\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":""}]}},"jetpack_featured_media_url":"https:\/\/res.cloudinary.com\/cloudinary-marketing\/images\/f_auto,q_auto\/v1681925193\/Web_Assets\/blog\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905\/05437ae6a1620be54a8a88148fbff1abca4fd983-1600x893-1_28182ef905.png?_i=AA","_links":{"self":[{"href":"https:\/\/cloudinary.com\/blog\/wp-json\/wp\/v2\/posts\/28181","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cloudinary.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cloudinary.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cloudinary.com\/blog\/wp-json\/wp\/v2\/users\/41"}],"replies":[{"embeddable":true,"href":"https:\/\/cloudinary.com\/blog\/wp-json\/wp\/v2\/comments?post=28181"}],"version-history":[{"count":0,"href":"https:\/\/cloudinary.com\/blog\/wp-json\/wp\/v2\/posts\/28181\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/cloudinary.com\/blog\/wp-json\/wp\/v2\/media\/28182"}],"wp:attachment":[{"href":"https:\/\/cloudinary.com\/blog\/wp-json\/wp\/v2\/media?parent=28181"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cloudinary.com\/blog\/wp-json\/wp\/v2\/categories?post=28181"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cloudinary.com\/blog\/wp-json\/wp\/v2\/tags?post=28181"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}