<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Roman Vladimirov</title>
    <description>The latest articles on DEV Community by Roman Vladimirov (@trueromanus).</description>
    <link>https://dev.to/trueromanus</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F995248%2F42dd017c-1c8b-45a3-8abb-3480b2a5b415.png</url>
      <title>DEV Community: Roman Vladimirov</title>
      <link>https://dev.to/trueromanus</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/trueromanus"/>
    <language>en</language>
    <item>
      <title>Running HTTP(s) queries every day with ArdorQuery: Part 6 global variables</title>
      <dc:creator>Roman Vladimirov</dc:creator>
      <pubDate>Mon, 29 Jan 2024 12:52:30 +0000</pubDate>
      <link>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-6-global-variables-22d1</link>
      <guid>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-6-global-variables-22d1</guid>
      <description>&lt;p&gt;If you're currently developing a web application, it's highly likely that you have an API, be it a REST API, a GraphQL API, or any other API. This means that HTTP queries must be made daily for development and testing. There are a huge number of tools available for running HTTP queries, such as cURL and Postman etc. I would like to tell you about a tool that I made for myself, but it might be useful for you too, it's called ArdorQuery. In this article, you will learn how to use the ArdorQuery application on a daily basis to make HTTP queries. The application is oriented on keyboard and allows you to separate parts of your query as human-readable lines. Lines are highlighted in different colors depending on the type of content. To get &lt;a href="https://trueromanus.github.io/ArdorQuery/"&gt;more information about application and install&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-5-multiple-queries-3ha9"&gt;&lt;em&gt;Previous post describing the use of multiple queries&lt;/em&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;So, we have already learned how to create and execute queries, but it often happens that a query consists of parts that are repeated quite often. For example, if authorization in a REST API is based on a token, then most requests require passing a token. Adding a token to each request can be quite tedious, but let's say I created ten requests and added all the tokens to them, but then I had to work with a different token, which means I need to open all ten requests and change the token manually. This is very inconvenient, so you can use another way and define global variables.&lt;br&gt;
To open the global variables window press &lt;code&gt;Ctrl-F6&lt;/code&gt;.&lt;br&gt;
&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqcxo21bgl90vr2btdnja.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqcxo21bgl90vr2btdnja.png" alt="Empty Window" width="593" height="523"&gt;&lt;/a&gt;&lt;br&gt;
Working with this window is similar as we do in editing query. Let's create a new global variable, to add a new variable press &lt;code&gt;Ctrl-Enter&lt;/code&gt;. Next, enter &lt;code&gt;apitoken mytokencontent&lt;/code&gt; in the empty line. The format of the global variable &lt;code&gt;&amp;lt;variable name&amp;gt; &amp;lt;value&amp;gt;&lt;/code&gt;.&lt;br&gt;
&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3zj61wqbmjbz7cffiizm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3zj61wqbmjbz7cffiizm.png" alt="Added token" width="595" height="121"&gt;&lt;/a&gt;&lt;br&gt;
After we done with editing global variables need to save it and for this press &lt;code&gt;Ctrl-S&lt;/code&gt;. To move through line, you can use &lt;code&gt;PgDown&lt;/code&gt; and &lt;code&gt;PgUp&lt;/code&gt; (also &lt;code&gt;Ctrl-PgDown&lt;/code&gt; to the end and &lt;code&gt;Ctrl-PgUp&lt;/code&gt; to the beginning).&lt;br&gt;
After this, you can add a global variable to any value of any field like this &lt;code&gt;{{&amp;lt;variable name&amp;gt;}}&lt;/code&gt;, in our case it will be &lt;code&gt;{{apitoken}}&lt;/code&gt;. Now we can add the &lt;code&gt;bearer {{apitoken}}&lt;/code&gt; header to several requests, and if in the future we need to replace it in all requests at once, it will be enough to change its value through the Global Variables window.&lt;br&gt;
&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl3bsg7aqs9m9k9z1pmxd.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl3bsg7aqs9m9k9z1pmxd.png" alt="Using in query" width="792" height="143"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Running HTTP(s) queries every day with ArdorQuery: Part 5 multiple queries</title>
      <dc:creator>Roman Vladimirov</dc:creator>
      <pubDate>Tue, 02 Jan 2024 12:12:20 +0000</pubDate>
      <link>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-5-multiple-queries-3ha9</link>
      <guid>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-5-multiple-queries-3ha9</guid>
      <description>&lt;p&gt;If you're currently developing a web application, it's highly likely that you have an API, be it a REST API, a GraphQL API, or any other API. This means that HTTP queries must be made daily for development and testing. There are a huge number of tools available for running HTTP queries, such as cURL and Postman etc. I would like to tell you about a tool that I made for myself, but it might be useful for you too, it's called ArdorQuery. In this article, you will learn how to use the ArdorQuery application on a daily basis to make HTTP queries. The application is oriented on keyboard and allows you to separate parts of your query as human-readable lines. Lines are highlighted in different colors depending on the type of content. To get more &lt;a href="https://trueromanus.github.io/ArdorQuery/"&gt;information about application or download&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;In previous articles we worked with one query, but in the real world the number of queries we have to work with at the same time is usually more than one. In ArdorQuery you can add any number of queries and switch between them at any time. First, you should learn about the &lt;code&gt;title X&lt;/code&gt; field, which allows you to add human-readable descriptions for queries. All queries that do not have a name will be named &lt;code&gt;Unnamed&lt;/code&gt;, and if all requests are called that way, you will agree that it will be difficult to distinguish between them.&lt;/p&gt;

&lt;p&gt;Now we are ready to make an example. Let's add field &lt;code&gt;title Get todos&lt;/code&gt; to our query. Changes will be immediately reflected in the tab header above the editor.  &lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--wP5ZSDON--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/8t9fhkbs8bf76j4j39ba.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--wP5ZSDON--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/8t9fhkbs8bf76j4j39ba.png" alt="Title todo" width="448" height="126"&gt;&lt;/a&gt;&lt;br&gt;
And add URL to get todo item &lt;code&gt;url https://jsonplaceholder.typicode.com/todos/1&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--HzAsiuFY--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mf4u0lpfs83x5eglgdyh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--HzAsiuFY--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mf4u0lpfs83x5eglgdyh.png" alt="Full todo query" width="452" height="153"&gt;&lt;/a&gt;&lt;br&gt;
Let's say I need to run another query, but I want to return to the one I already created and continue working with it. To add a new request, you need use &lt;code&gt;Ctrl-Insert&lt;/code&gt;. After this, we will immediately move to a new request and it will be empty. Let's fill out a new query, define the request title &lt;code&gt;title Get posts&lt;/code&gt; and &lt;code&gt;url https://jsonplaceholder.typicode.com/posts/1&lt;/code&gt;. To see what queries there are in the form of a list, you can click on the icon in the tab with the editor's request. &lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--scjwRnYz--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4ajem71xjxahg5xsv0zt.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--scjwRnYz--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4ajem71xjxahg5xsv0zt.png" alt="List of queries" width="553" height="411"&gt;&lt;/a&gt;&lt;br&gt;
You can click on the corresponding item and it will open.&lt;/p&gt;

&lt;p&gt;But besides this, there is another more convenient way.&lt;br&gt;
Navigate between queries — press and hold the &lt;code&gt;Ctrl&lt;/code&gt; button, then press and release &lt;code&gt;Tab&lt;/code&gt; (T on macOS) to open the history window. The position in history will correspond to the most recently opened query. You can hold down the &lt;code&gt;Ctrl&lt;/code&gt; key and press &lt;code&gt;Tab&lt;/code&gt; (&lt;code&gt;T&lt;/code&gt; on macOS) repeatedly to select the query you want from the list from up to down, and when you release the &lt;code&gt;Ctrl&lt;/code&gt; key, the selected query will immediately open. This option is more convenient when you need to switch between queries frequently.&lt;/p&gt;

&lt;p&gt;You can also run all queries at once by pressing &lt;code&gt;Ctrl-M&lt;/code&gt;. You can track the execution of queries in the lower toolbar.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Do5U7-g3--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zl1c108mkc1kuyfo3atg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Do5U7-g3--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zl1c108mkc1kuyfo3atg.png" alt="Count of completed requests" width="795" height="627"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Running HTTP(s) queries every day with ArdorQuery: Part 4 routes and URL parameters</title>
      <dc:creator>Roman Vladimirov</dc:creator>
      <pubDate>Tue, 07 Nov 2023 08:57:19 +0000</pubDate>
      <link>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-4-routes-and-url-parameters-g85</link>
      <guid>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-4-routes-and-url-parameters-g85</guid>
      <description>&lt;p&gt;If you're currently developing a web application, it's highly likely that you have an API, be it a REST API, a GraphQL API, or any other API. This means that HTTP queries must be made daily for development and testing. There are a huge number of tools available for running HTTP queries, such as cURL and Postman etc. I would like to tell you about a tool that I made for myself, but it might be useful for you too, it's called ArdorQuery. In this article, you will learn how to use the ArdorQuery application on a daily basis to make HTTP queries. The application is oriented on keyboard and allows you to separate parts of your query as human-readable lines. Lines are highlighted in different colors depending on the type of content. To get more &lt;a href="https://trueromanus.github.io/ArdorQuery/"&gt;information about application or download&lt;/a&gt;. In this part, we will discuss how to work with routes and URL parameters.&lt;/p&gt;

&lt;p&gt;A URL path is an integral part of an HTTP request that acts as a path to the desired destination. This applies to both the path described in the manner of folders on the local disk separated by the symbols / (for example &lt;code&gt;/building1/room1/Alice/apple&lt;/code&gt;) and additional parameters after the path listed after the symbol ? (like &lt;code&gt;?color=green&amp;amp;size=large&lt;/code&gt;). Both the path and the parameters are described by one continuous line. If the path is long and/or there are many parameters, the one-line representation is not always easy to read. In the application, you can split both the path and parameters into separate lines.&lt;/p&gt;

&lt;p&gt;Let's say we have a URL &lt;code&gt;https://mysite.com/products/tablet/product/1?company=samsung&amp;amp;monitorsize=8&lt;/code&gt;. Here we choose&lt;br&gt;
for a user with &lt;code&gt;id=1&lt;/code&gt; from the &lt;code&gt;products&lt;/code&gt; of a certain store, a product with a category &lt;code&gt;tablet&lt;/code&gt; and a filter by company &lt;code&gt;samsung&lt;/code&gt; with a monitor size of &lt;code&gt;8&lt;/code&gt; inches.&lt;/p&gt;

&lt;p&gt;Let's now add this URL to the application &lt;code&gt;url https://mysite.com/products/{category}/product/{userid}&lt;/code&gt;.&lt;br&gt;
As you can see, we have replaced the &lt;code&gt;category&lt;/code&gt; and &lt;code&gt;userid&lt;/code&gt; with named parameters ({category} and {userid}). Named parameters are defined in the format {parameter name}.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Fw8DAPLt--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ulvu3sgh87rxivlnaojz.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Fw8DAPLt--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ulvu3sgh87rxivlnaojz.png" alt="Filled url field" width="798" height="129"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Next you need to add values for the named parameters. To do this, add a line with the content &lt;code&gt;route category=tablet&lt;/code&gt; and another line with the content &lt;code&gt;route userid=1&lt;/code&gt;. This way, if we need to change part of route for a &lt;code&gt;category&lt;/code&gt; or &lt;code&gt;userid&lt;/code&gt;, we can do it on separate lines with a clear name, which is more convenient than doing it in the query string itself.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--lpA1QxC_--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/8he1bdxu3uq1j9yvaddi.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--lpA1QxC_--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/8he1bdxu3uq1j9yvaddi.png" alt="Filled routes" width="797" height="183"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;We forgot something, what about URL parameters? To define them, we add two more lines: &lt;code&gt;param сompany=samsung&lt;/code&gt; and &lt;code&gt;param monitorsize=8&lt;/code&gt;. If you perform query you will see that we've make query with same URL as in the original form, but now we can change both routes and the URL parameters separately in a more readable form.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--aOmpjuIg--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qakyrvofk1rcr9ee4qp2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--aOmpjuIg--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qakyrvofk1rcr9ee4qp2.png" alt="Filled params" width="796" height="241"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Running HTTP(s) queries every day with ArdorQuery: Part 3 HTTP Headers</title>
      <dc:creator>Roman Vladimirov</dc:creator>
      <pubDate>Sat, 21 Oct 2023 14:32:55 +0000</pubDate>
      <link>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-3-http-headers-21c5</link>
      <guid>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-3-http-headers-21c5</guid>
      <description>&lt;p&gt;If you're currently developing a web application, it's highly likely that you have an API, be it a REST API, a GraphQL API, or any other API. This means that HTTP queries must be made daily for development and testing. There are a huge number of tools available for running HTTP queries, such as cURL and Postman etc. I would like to tell you about a tool that I made for myself, but it might be useful for you too, it's called ArdorQuery. In this article, you will learn how to use the ArdorQuery application on a daily basis to make HTTP queries. The application is oriented on keyboard and allows you to separate parts of your query as human-readable strings. Strings are highlighted in different colors depending on the type of content. More &lt;a href="https://github.com/trueromanus/ArdorQuery"&gt;information about application or download&lt;/a&gt;. In this part, we will discuss how to work with HTTP Headers.&lt;/p&gt;

&lt;p&gt;HTTP Headers are an important part of an HTTP query; using them we can specify many different things, for example what type of content we can accept, how to compress the response and much more.&lt;br&gt;
To add a HTTP Header in an application, add a new line by pressing (Ctrl-Enter). The HTTP protocol has a standard set of headers such as &lt;code&gt;Authorization&lt;/code&gt;, &lt;code&gt;Content-Type&lt;/code&gt;, etc. Standard HTTP Headers can be specified in the format &lt;code&gt;&amp;lt;Header Name&amp;gt; &amp;lt;Header Value&amp;gt;&lt;/code&gt;. For example, to define the request type, you need to write &lt;code&gt;Content-Type application/json&lt;/code&gt;. To specify a bearer token, you need to write &lt;code&gt;Authorization Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9&lt;/code&gt;.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--f80Wmc9E--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/sxlwv4wrjxsd3ijkz8l7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--f80Wmc9E--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/sxlwv4wrjxsd3ijkz8l7.png" alt="Standart Header Example" width="797" height="215"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In addition to standard headers, you can use non-standard ones that support only specific websites or services. Some time ago, it was fashionable to add an &lt;code&gt;X-&lt;/code&gt; prefix to non-standard HTTP Headers to visually distinguish them from standard ones. The application supports such headers, you can write as example &lt;code&gt;X-MYCUSTOMHEADER 123&lt;/code&gt;.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--4VzAmcQ5--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1o738n8iluw13baqks0o.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--4VzAmcQ5--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1o738n8iluw13baqks0o.png" alt="Non standart header example" width="797" height="234"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The modern way to add non-standard HTTP Headers is to simply add any words or combinations of words that are not in the standard set and use it on your server. In application you can create new line with following content &lt;code&gt;header &amp;lt;Header Name&amp;gt; &amp;lt;Header Value&amp;gt;&lt;/code&gt;. &lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--kXvknG9u--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/f4wsnnyn5rg6hewppna7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--kXvknG9u--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/f4wsnnyn5rg6hewppna7.png" alt="Moder header example" width="797" height="181"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;When sending requests, the application will only add HTTP Headers needed to complete the request. You can override all the standard HTTP Headers if you want to have more control over which headers and values should be part of the request.&lt;/p&gt;

&lt;p&gt;Among the standard headers is the cookie header. It represents itself as a dictionary and can contains session specific data. The contents of the dictionary are written as a single delimited string. It is not always convenient to fill out this header as a single line, so you can set values for individual keys for this header creating line with content &lt;code&gt;pastry &amp;lt;cookie key&amp;gt;=&amp;lt;value&amp;gt;&lt;/code&gt;. As example &lt;code&gt;pastry TOKEN=MYTOKEN123&lt;/code&gt;. But you need to know if you define header &lt;code&gt;Cookie&lt;/code&gt; itself, all lines with pastry fields will be ignored.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Running HTTP(s) queries every day with ArdorQuery: Part 2 HTTP Forms and files</title>
      <dc:creator>Roman Vladimirov</dc:creator>
      <pubDate>Tue, 17 Oct 2023 18:19:05 +0000</pubDate>
      <link>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-2-http-forms-and-files-2k9b</link>
      <guid>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-2-http-forms-and-files-2k9b</guid>
      <description>&lt;p&gt;If you're currently developing a web application, it's highly likely that you have an API, be it a REST API, a GraphQL API, or any other API. This means that HTTP queries must be made daily for development and testing. There are a huge number of tools available for running HTTP queries, such as cURL and Postman etc. I would like to tell you about a tool that I made for myself, but it might be useful for you too, it's called ArdorQuery. In this article, you will learn how to use the ArdorQuery application on a daily basis to make HTTP queries. The application is oriented on keyboard and allows you to separate parts of your query as human-readable strings. Strings are highlighted in different colors depending on the type of content. More &lt;a href="https://github.com/trueromanus/ArdorQuery"&gt;information about application or download&lt;/a&gt;. In this part, we will discuss how to work with HTTP Forms and files in application.&lt;/p&gt;

&lt;p&gt;Although the API has practically replaced the need for using HTTP Forms but this does not mean that HTTP Forms are not needed at all. For example, HTTP Forms are a standard file transfer method that is still used in hundreds (and thousands) of websites today. HTTP Forms are a kind of dictionary, where the key is the name of parameter, and the value is the text or binary in case of file.&lt;/p&gt;

&lt;p&gt;For defining HTTP Forms in application, we need to define form fields.&lt;br&gt;
To do this, you need to add a new line to the application and fill it as &lt;code&gt;form &amp;lt;field name&amp;gt;=&amp;lt;value&amp;gt;&lt;/code&gt; there.&lt;br&gt;
For example, to add a count field with a value of 100, you would create line with the content &lt;code&gt;form count=100&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--j2TraM67--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/st5tfhu35j84s18ypajt.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--j2TraM67--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/st5tfhu35j84s18ypajt.png" alt="Example of form" width="795" height="182"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Add the required number of lines for each required form field. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--2mwkW3th--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/hi90ka8592b3ske9f2f7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--2mwkW3th--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/hi90ka8592b3ske9f2f7.png" alt="Example of form 2" width="796" height="287"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It is also worth noting that body transfer is only supported for requests using the POST and PUT methods. So you need to add a line specifying one of these methods (like &lt;code&gt;method POST&lt;/code&gt; or &lt;code&gt;method PUT&lt;/code&gt;). Form fields are added to the request body, which means that if you have defined a request body (using body fields as &lt;code&gt;json X&lt;/code&gt;, &lt;code&gt;xmla X&lt;/code&gt;, &lt;code&gt;body X&lt;/code&gt;), then the form fields will be ignored!&lt;/p&gt;

&lt;p&gt;To send a file, you need to create a line with the content &lt;code&gt;file &amp;lt;field name&amp;gt;=&amp;lt;path to file&amp;gt;&lt;/code&gt;. For example, to send the file &lt;code&gt;background.png&lt;/code&gt; from the &lt;code&gt;c:/myimages/&lt;/code&gt; folder to parameter &lt;code&gt;backgroundimage&lt;/code&gt;, you need to add a line with the content &lt;code&gt;file backgroundimage=c:/myimages/background.png&lt;/code&gt;. File fields and form fields can be combined in single HTTP Form. Just like for a form field, you need to create a corresponding line for each file.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--eI8O4Uy_--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5hzojfv4z9b588qthmi6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--eI8O4Uy_--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5hzojfv4z9b588qthmi6.png" alt="Example of files" width="797" height="357"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In the next part I describe how to add HTTP Headers to query.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Running HTTP(s) queries every day with ArdorQuery: Part 1 Intro</title>
      <dc:creator>Roman Vladimirov</dc:creator>
      <pubDate>Sun, 15 Oct 2023 14:49:56 +0000</pubDate>
      <link>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-1-intro-54d6</link>
      <guid>https://dev.to/trueromanus/running-https-queries-every-day-with-ardorquery-part-1-intro-54d6</guid>
      <description>&lt;p&gt;If you're currently developing a web application, it's highly likely that you have an API, be it a REST API, a GraphQL API, or any other API. This means that HTTP queries must be made daily for development and testing. There are a huge number of tools available for running HTTP queries, such as cURL and Postman etc. I would like to tell you about a tool that I made for myself, but it might be useful for you too, it's called ArdorQuery. In this article, you will learn how to use the ArdorQuery application on a daily basis to make HTTP queries. The application is oriented on keyboard and allows you to separate parts of your query as human-readable strings. Strings are highlighted in different colors depending on the type of content. More &lt;a href="https://github.com/trueromanus/ArdorQuery"&gt;information about application or download&lt;/a&gt;. But less words and more action.&lt;/p&gt;

&lt;p&gt;Let's try to make a simple HTTP query.&lt;/p&gt;

&lt;p&gt;Launch the application and enter the following into the single text field:&lt;br&gt;
&lt;code&gt;url https://jsonplaceholder.typicode.com/todos/1&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--FkQfTKlN--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kigo8f9ub4beoppagqez.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--FkQfTKlN--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kigo8f9ub4beoppagqez.png" alt="Filled screenshot" width="798" height="141"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Next, press &lt;code&gt;Ctrl-Z&lt;/code&gt; to perform the query.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--xr-rcNCa--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/shmz8i3f2317izf1tsqr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--xr-rcNCa--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/shmz8i3f2317izf1tsqr.png" alt="Perform status" width="503" height="144"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;To view the query result, press on &lt;code&gt;F11&lt;/code&gt;. You can also switch back to editing the query by pressing &lt;code&gt;F11&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--xqd-O19r--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tm1s043xw9d857kxekny.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--xqd-O19r--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tm1s043xw9d857kxekny.png" alt="query result" width="800" height="630"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Here we see the status of the execution result and how much time it took to complete the query, the size and headers of the response, as well as response body. In our example, we get the result as &lt;code&gt;JSON&lt;/code&gt;. For &lt;code&gt;JSON&lt;/code&gt; syntax, the program provides syntax highlighting and formatting.&lt;/p&gt;

&lt;p&gt;If for some reason the result in the body is in the form of &lt;code&gt;JSON&lt;/code&gt;, but the program could not clearly determine this, then you can select the markup explicitly in the drop-down in the center of the body header.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--By_1grLk--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/g4p2h4rhajg9ywgw736i.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--By_1grLk--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/g4p2h4rhajg9ywgw736i.png" alt="Select formatter" width="798" height="83"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Autodetect, selected by default, determines formatting based on the contents of the &lt;code&gt;Content-Type&lt;/code&gt; response header.&lt;/p&gt;

&lt;p&gt;Now let's go back to the query editor and try to send a POST query with a body. To do this, press Tab to return to the query editor. Change the text in the field to &lt;code&gt;url https://jsonplaceholder.typicode.com/todos&lt;/code&gt; and remove the &lt;code&gt;/1&lt;/code&gt; at the end. Then press &lt;code&gt;Ctrl-Enter&lt;/code&gt; to add a new line and&lt;br&gt;
enter the text &lt;code&gt;method POST&lt;/code&gt; into it. This way we indicate that we should not use the GET method, which is used by default, but POST.&lt;br&gt;
To add another string, press &lt;code&gt;Ctrl-Enter&lt;/code&gt; and enter &lt;code&gt;json {"container": {"field": 10}}&lt;/code&gt; there. This way we indicate that we want to define the body of our request in &lt;code&gt;JSON&lt;/code&gt; format and define the content as a simple structure &lt;code&gt;{"container": {"field": 10}}&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--KUIZflD2--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ijz6duym59m0o31zh0ei.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--KUIZflD2--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ijz6duym59m0o31zh0ei.png" alt="Fields for post query" width="797" height="173"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Our query is ready, we run it as before, pressing &lt;code&gt;Ctrl-Z&lt;/code&gt; and after it press &lt;code&gt;F11&lt;/code&gt; to jump to its result. As a result, you will see in the body of the response the same JSON that we sent in the field where you specified the contents of the body to be sent.&lt;br&gt;
So we were able to set up a simple query, run it, and view the results.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--G7n7MOfc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mvvdrqik4uzubk73722x.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--G7n7MOfc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mvvdrqik4uzubk73722x.png" alt="Final result" width="800" height="630"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;You can check all the keyboard shortcuts by pressing &lt;code&gt;F1&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;In the next part we will work with HTTP Forms and files.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>5 Vue.js slot tricks to watch out for</title>
      <dc:creator>Roman Vladimirov</dc:creator>
      <pubDate>Fri, 06 Jan 2023 18:47:55 +0000</pubDate>
      <link>https://dev.to/trueromanus/5-vuejs-slot-tricks-to-watch-out-for-5g6o</link>
      <guid>https://dev.to/trueromanus/5-vuejs-slot-tricks-to-watch-out-for-5g6o</guid>
      <description>&lt;p&gt;Vue.js is a powerful library for creating user interfaces for web and mobile platforms. It is part of the so-called big three (also Angular and React) libraries for interactive user interface programming. I think you use slots all the time when using Vue.js. It's so simple and intuitive mechanism that it is a pleasure to use it. Slots are everywhere, in libraries, in components, and in scaffolders. But for the most part, everyone uses them only on one side, on the side of consumption, and when creating their components, they are rarely added. In this article I will show you how easy it is to add slots into your own components and a few cases where they can save a couple of lines of code.&lt;/p&gt;

&lt;h2&gt;
  
  
  Preface
&lt;/h2&gt;

&lt;p&gt;First, what is a slot in Vue.js. A slot is a special communication mechanism between components. Yes, you should think about slots&lt;br&gt;
not as a mechanism for inserting content, but as a mechanism for communication between components. So, in all examples, we will have two components &lt;code&gt;TestParent.vue&lt;/code&gt; and &lt;code&gt;TestChildren.vue&lt;/code&gt;. I will not use &lt;code&gt;TypeScript&lt;/code&gt; and &lt;code&gt;Composition API&lt;/code&gt; to keep all examples as simple as possible.&lt;br&gt;
The simplest example of communication through slots:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="c"&gt;&amp;lt;!-- TestParent.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;test-children&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;span&amp;gt;&lt;/span&gt;World&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;/test-children&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;script&amp;gt;&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;TestChildren&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="p"&gt;...&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;`Parent`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="na"&gt;components&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;TestChildren&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/script&amp;gt;&lt;/span&gt; 

&lt;span class="c"&gt;&amp;lt;!-- TestChildren.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;span&amp;gt;&lt;/span&gt;Hello&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;slot&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;As a result, we will get the text &lt;code&gt;Hello World&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;In our example, I used the so-called default slot. You can define more slots, for example let's add another slot to indicate an exclamation point.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="c"&gt;&amp;lt;!-- TestParent.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;test-children&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;span&amp;gt;&lt;/span&gt;World&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:extra&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
                !
            &lt;span class="nt"&gt;&amp;lt;/template&lt;/span&gt;          
        &lt;span class="err"&gt;&amp;lt;/test-children&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;        
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
&lt;span class="c"&gt;&amp;lt;!--
I omitted the script section because it
hasn't changed from the previous example
--&amp;gt;&lt;/span&gt;

&lt;span class="c"&gt;&amp;lt;!-- TestChildren.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;span&amp;gt;&lt;/span&gt;Hello&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;slot&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"extra"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The result is &lt;code&gt;Hello World !&lt;/code&gt;. Here we have added a named slot called &lt;code&gt;extra&lt;/code&gt; where we added an exclamation mark. You can add as many named slots as you want to your component. You can even create them dynamically.&lt;/p&gt;

&lt;p&gt;So, we are ready to move on to cases that can be useful in the daily creation of components.&lt;/p&gt;

&lt;h2&gt;
  
  
  Case 1: Consolidation of functionality
&lt;/h2&gt;

&lt;p&gt;Suppose the &lt;code&gt;TestChildren&lt;/code&gt; component displays text with formatting that removes edge spaces (trim operation). It also has an additional slot for displaying additional text. We add additional text in the &lt;code&gt;TestParent&lt;/code&gt; component.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="c"&gt;&amp;lt;!-- TestParent.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;test-children&lt;/span&gt; &lt;span class="na"&gt;header=&lt;/span&gt;&lt;span class="s"&gt;"Hello"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:extra&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
                {{ parentValue }}
            &lt;span class="nt"&gt;&amp;lt;/template&lt;/span&gt;
        &lt;span class="err"&gt;&amp;lt;/test-children&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;script&amp;gt;&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;TestChildren&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="p"&gt;...&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;`Parent`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="na"&gt;components&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;TestChildren&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
        &lt;span class="nf"&gt;data&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="na"&gt;parentValue&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;World!&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/script&amp;gt;&lt;/span&gt; 

&lt;span class="c"&gt;&amp;lt;!-- TestChildren.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="c"&gt;&amp;lt;!-- Using a formatting method --&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;span&amp;gt;&lt;/span&gt;{{ formatValue(header) }}&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"extra"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;script&amp;gt;&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;`TestChildren`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="na"&gt;props&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="na"&gt;header&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;String&lt;/span&gt;
        &lt;span class="p"&gt;},&lt;/span&gt;
        &lt;span class="na"&gt;methods&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="c1"&gt;// we have added a new formatting method&lt;/span&gt;
            &lt;span class="nf"&gt;formatValue&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; 
                &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;trim&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/script&amp;gt;&lt;/span&gt; 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;All goes well until we get a request to also format the &lt;code&gt;parentValue&lt;/code&gt; in the &lt;code&gt;TestParent&lt;/code&gt;. The problem here is that the formatting function is in the &lt;code&gt;TestChildren&lt;/code&gt; component. You can naturally take out the &lt;code&gt;formatValue&lt;/code&gt; function from the component into a separate js / ts file and import it to both components. But what if I will say that you can do this without separating the function into a separate script file. You can use the functionality of the slots to solve this problem. Let's change it so that we can use this function from the &lt;code&gt;TestParent&lt;/code&gt; component.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="c"&gt;&amp;lt;!-- TestParent.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;test-children&lt;/span&gt; &lt;span class="na"&gt;header=&lt;/span&gt;&lt;span class="s"&gt;"Hello"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:extra=&lt;/span&gt;&lt;span class="s"&gt;"{ format }"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt; 
                &lt;span class="c"&gt;&amp;lt;!-- call the method to format the value --&amp;gt;&lt;/span&gt;
                {{ format(parentValue) }} 
            &lt;span class="nt"&gt;&amp;lt;/template&lt;/span&gt;
        &lt;span class="err"&gt;&amp;lt;/test-children&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
&lt;span class="c"&gt;&amp;lt;!-- script section stay as in previous example --&amp;gt;&lt;/span&gt;

&lt;span class="c"&gt;&amp;lt;!-- TestChildren.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;span&amp;gt;&lt;/span&gt;{{ formatValue(header) }}&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"extra"&lt;/span&gt; &lt;span class="na"&gt;:format=&lt;/span&gt;&lt;span class="s"&gt;"formatValue"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;script&amp;gt;&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;`TestChildren`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="na"&gt;props&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="na"&gt;header&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;String&lt;/span&gt;
        &lt;span class="p"&gt;},&lt;/span&gt;
        &lt;span class="na"&gt;methods&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="nf"&gt;formatValue&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;trim&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/script&amp;gt;&lt;/span&gt; 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;As we see, we got result without using extra files just inside our components. The &lt;code&gt;TestChildren&lt;/code&gt; component exposes the function for the &lt;code&gt;TestParent&lt;/code&gt; component only in the slot definition.&lt;/p&gt;

&lt;h2&gt;
  
  
  Case 2: Component without UI
&lt;/h2&gt;

&lt;p&gt;This case is an extension of the previous case to the entire component. Let's say we have a small (or maybe vice versa large) component, but each time it is used, a different representation must be used. A simple example is a button, a button can be in the form of a rectangle and as a link, as an icon, etc. How to solve this problem? We can create a component in which we describe the logic of how it should work (methods and properties) and when using an external component, it will decide which view it should use.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="c"&gt;&amp;lt;!-- TestParent.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;test-children&lt;/span&gt;
            &lt;span class="na"&gt;title=&lt;/span&gt;&lt;span class="s"&gt;"Say Hello World!"&lt;/span&gt;
            &lt;span class="err"&gt;@&lt;/span&gt;&lt;span class="na"&gt;clicked=&lt;/span&gt;&lt;span class="s"&gt;"fire()"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;#default&lt;/span&gt;&lt;span class="err"&gt;="{&lt;/span&gt; &lt;span class="na"&gt;context&lt;/span&gt; &lt;span class="err"&gt;}"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="c"&gt;&amp;lt;!--
                    We use context to create a view for the button.
                --&amp;gt;&lt;/span&gt;
                &lt;span class="nt"&gt;&amp;lt;button&lt;/span&gt;
                    &lt;span class="err"&gt;@&lt;/span&gt;&lt;span class="na"&gt;click=&lt;/span&gt;&lt;span class="s"&gt;"context.click($event)"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
                    &lt;span class="nt"&gt;&amp;lt;span&amp;gt;&lt;/span&gt;
                        {{ context.title }}
                    &lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
                &lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;/test-children&amp;gt;&lt;/span&gt;    
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;script&amp;gt;&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;TestChildren&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="p"&gt;...&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;`Parent`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="na"&gt;components&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;TestChildren&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
        &lt;span class="nf"&gt;data&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="p"&gt;},&lt;/span&gt;
        &lt;span class="na"&gt;methods&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="nf"&gt;fire&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="nb"&gt;window&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;alert&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Hello World!&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/script&amp;gt;&lt;/span&gt;

&lt;span class="c"&gt;&amp;lt;!-- TestChildren.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="c"&gt;&amp;lt;!-- We put the whole component in the context variable --&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;:context=&lt;/span&gt;&lt;span class="s"&gt;"this"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt; 
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;script&amp;gt;&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;`TestChildren`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;props&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="na"&gt;title&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="na"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;String&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="na"&gt;default&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="s2"&gt;``&lt;/span&gt;
        &lt;span class="p"&gt;},&lt;/span&gt;
        &lt;span class="na"&gt;disable&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="na"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;Boolean&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="na"&gt;default&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="na"&gt;emits&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;`clicked`&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
    &lt;span class="na"&gt;methods&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="nf"&gt;click&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;$event&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;disable&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
            &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;$emit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`clicked`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;$event&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/script&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;code&gt;TestChildren&lt;/code&gt; component contains a set of properties (&lt;code&gt;title&lt;/code&gt; and &lt;code&gt;disable&lt;/code&gt;) and a &lt;code&gt;click&lt;/code&gt; method. This state and behavior is the same in all buttons regardless of how they look. In this way, we can save code by not creating the same type of components that just look different but have the same functionality.&lt;/p&gt;

&lt;h2&gt;
  
  
  Case 3: Rollover slots
&lt;/h2&gt;

&lt;p&gt;Let's say we have three components, first &lt;code&gt;SomeComponent&lt;/code&gt; in which there are several slots (among which there are &lt;code&gt;header&lt;/code&gt; and &lt;code&gt;footer&lt;/code&gt;).&lt;br&gt;
It is imported within second &lt;code&gt;TestChildren&lt;/code&gt; component and it defines the content for all the slots of the &lt;code&gt;SomeComponent&lt;/code&gt; component, plus some functionality. And we have third &lt;code&gt;TestParent&lt;/code&gt; component where imported &lt;code&gt;TestChildren&lt;/code&gt;. At some point in time, there is a need to change the content for slots in different situations, but only for &lt;code&gt;header&lt;/code&gt; and &lt;code&gt;footer&lt;/code&gt; everything else remains as is. I have a component (perhaps complex) but I need to somehow definition content for slot from the parent component for the slot of the component nested in different component. Let's take an example, in the &lt;code&gt;TestParent&lt;/code&gt; component, I should be able to change the content of the &lt;code&gt;footer&lt;/code&gt; slot in the &lt;code&gt;SomeComponent&lt;/code&gt; component, which is imported within &lt;code&gt;TestChildren&lt;/code&gt; component.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;
&lt;span class="c"&gt;&amp;lt;!-- SomeComponent.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"header"&lt;/span&gt; &lt;span class="na"&gt;:message=&lt;/span&gt;&lt;span class="s"&gt;"'value is '"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"footer"&lt;/span&gt; &lt;span class="na"&gt;:value=&lt;/span&gt;&lt;span class="s"&gt;"1"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="c"&gt;&amp;lt;!-- TestChildren.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;some-component&amp;gt;&lt;/span&gt;
        &lt;span class="c"&gt;&amp;lt;!-- Here we rollover the header and footer slots --&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:header=&lt;/span&gt;&lt;span class="s"&gt;"{ message }"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"header"&lt;/span&gt; &lt;span class="na"&gt;:message=&lt;/span&gt;&lt;span class="s"&gt;"message"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt; 
        &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:footer=&lt;/span&gt;&lt;span class="s"&gt;"{ value }"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"footer"&lt;/span&gt; &lt;span class="na"&gt;:value=&lt;/span&gt;&lt;span class="s"&gt;"value"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

        &lt;span class="c"&gt;&amp;lt;!-- definition for other slots and other stuff --&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/some-component&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="c"&gt;&amp;lt;!-- TestParent.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;test-children&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:header=&lt;/span&gt;&lt;span class="s"&gt;"{ message }"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="nt"&gt;&amp;lt;span&lt;/span&gt; &lt;span class="na"&gt;style=&lt;/span&gt;&lt;span class="s"&gt;"color: red;"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;{{ message }}&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:footer=&lt;/span&gt;&lt;span class="s"&gt;"{ value }"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="nt"&gt;&amp;lt;span&lt;/span&gt; &lt;span class="na"&gt;style=&lt;/span&gt;&lt;span class="s"&gt;"color: green;"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;{{ value }}&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;/test-children&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;As a result, we get &lt;code&gt;value is 1&lt;/code&gt; but written in different colors. I draw your attention to the fact that in addition to the slots themselves, I pass the &lt;code&gt;message&lt;/code&gt; and &lt;code&gt;value&lt;/code&gt; parameters for the slots. This approach allows you to rollover some slots for the parent component from other the component, increasing the customization of the all components.&lt;/p&gt;

&lt;h2&gt;
  
  
  Case 4: Data change chain
&lt;/h2&gt;

&lt;p&gt;I am using the same components as in the previous example to illustrate the idea. In the previous example, we just rollover from one slot to another the data of the &lt;code&gt;header&lt;/code&gt; and &lt;code&gt;footer&lt;/code&gt; slots, but what if I tell you that we can change them during the rollover.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;
&lt;span class="c"&gt;&amp;lt;!-- SomeComponent.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"header"&lt;/span&gt; &lt;span class="na"&gt;:message=&lt;/span&gt;&lt;span class="s"&gt;"'value is '"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"footer"&lt;/span&gt; &lt;span class="na"&gt;:value=&lt;/span&gt;&lt;span class="s"&gt;"1"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="c"&gt;&amp;lt;!-- TestChildren.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;some-component&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:header=&lt;/span&gt;&lt;span class="s"&gt;"{ message }"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="c"&gt;&amp;lt;!-- transform message to upper case --&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt;
                &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"header"&lt;/span&gt;
                &lt;span class="na"&gt;:message=&lt;/span&gt;&lt;span class="s"&gt;"message.toUpperCase()"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;/slot&amp;gt;&lt;/span&gt; 
        &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:footer=&lt;/span&gt;&lt;span class="s"&gt;"{ value }"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="c"&gt;&amp;lt;!-- multiply on ten --&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"footer"&lt;/span&gt; &lt;span class="na"&gt;:value=&lt;/span&gt;&lt;span class="s"&gt;"value * 10"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

        &lt;span class="c"&gt;&amp;lt;!-- definition for other slots and other stuff --&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/some-component&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="c"&gt;&amp;lt;!-- TestParent.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;test-children&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:header=&lt;/span&gt;&lt;span class="s"&gt;"{ message }"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="nt"&gt;&amp;lt;span&amp;gt;&lt;/span&gt;{{ message + ":" }}&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:footer=&lt;/span&gt;&lt;span class="s"&gt;"{ value }"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="nt"&gt;&amp;lt;span&amp;gt;&lt;/span&gt;{{ value / 10 }}&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;/test-children&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Result: &lt;code&gt;VALUE: 1&lt;/code&gt;. Although this example seems to be extremely simple, imagine what can be done based on this idea. For example, destructuring a large object into small ones or vice versa. And note that the scope of such transformations does not go beyond the components, each component is have its own responsibility and knows nothing about data transformations in other components.&lt;/p&gt;

&lt;h2&gt;
  
  
  Case 5: Combining slots
&lt;/h2&gt;

&lt;p&gt;Let's say we have some component &lt;code&gt;SomeComponent&lt;/code&gt; and it has two slots - &lt;code&gt;header&lt;/code&gt;, &lt;code&gt;footer&lt;/code&gt;. Sometimes it happens that both of these slots must contain the same content. To solve this problem, we will make a &lt;code&gt;TestChildren&lt;/code&gt; component which will imported  &lt;code&gt;SomeComponent&lt;/code&gt; but define only one &lt;code&gt;postcontent&lt;/code&gt; slot and insert it into the &lt;code&gt;header&lt;/code&gt; and &lt;code&gt;footer&lt;/code&gt; slots.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="c"&gt;&amp;lt;!-- TestParent.vue --&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;test-children&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:postcontent&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="nt"&gt;&amp;lt;span&amp;gt;&lt;/span&gt;Header and Footer Message&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;/test-children&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;

&lt;span class="c"&gt;&amp;lt;!-- TestChildren.vue --&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;some-component&amp;gt;&lt;/span&gt;
        &lt;span class="c"&gt;&amp;lt;!-- insert the postcontent slot definition into the header and footer slots --&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:header&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"postcontent"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt; 
        &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;template&lt;/span&gt; &lt;span class="na"&gt;v-slot:footer&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="nt"&gt;&amp;lt;slot&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"postcontent"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/slot&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/some-component&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/template&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Thus, from the point of view of the &lt;code&gt;TestParent&lt;/code&gt; component, there is only one slot, which is actually multiplied by several places. Although this case seems highly unlikely, if you take a close look at your components, you will most likely find similar cases. For example, the title text of a blog post is repeated at the beginning of the article, in the header, in some kind of drop-down panel, etc.&lt;/p&gt;

&lt;h2&gt;
  
  
  Afterword
&lt;/h2&gt;

&lt;p&gt;I hope you find my tricks for Vue.js slots was interesting and will be useful for someone.&lt;/p&gt;

</description>
      <category>emptystring</category>
    </item>
    <item>
      <title>ArdorQuery release 0.0.6</title>
      <dc:creator>Roman Vladimirov</dc:creator>
      <pubDate>Fri, 23 Dec 2022 13:18:36 +0000</pubDate>
      <link>https://dev.to/trueromanus/ardorquery-release-006-57fp</link>
      <guid>https://dev.to/trueromanus/ardorquery-release-006-57fp</guid>
      <description>&lt;p&gt;ArdorQuery it is a tool for testing HTTP(s) endpoints (inspired from Postman and cURL) oriented on working from keyboard. If you want to know the purpose of the application, you can check other &lt;a href="https://medium.com/@trueromanus/another-tool-for-testing-http-s-fa607dbf3bca"&gt;post&lt;/a&gt;. In this post I tell you about important updates happend in new version 0.0.6. You can download the new version from &lt;a href="https://github.com/trueromanus/ArdorQuery/releases/tag/0.0.6"&gt;this link&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Route field
&lt;/h2&gt;

&lt;p&gt;In modern RESTful services widely used URL with dynamic segments. As example if I have this pattern &lt;strong&gt;http://../api/{dynamic-segment}/id&lt;/strong&gt;.&lt;br&gt;
This approach can be used and for routing (like &lt;strong&gt;http://../api/product/id , http://../api/user/id&lt;/strong&gt;) and as replace for URL parameter (like &lt;strong&gt;http://../api/1/id&lt;/strong&gt; , &lt;strong&gt;http://../api/500/id&lt;/strong&gt;).&lt;br&gt;
For adding dynamic segments in ArdorQuery you need create named dynamic segment in url in format &lt;strong&gt;{nameofsegment}&lt;/strong&gt;.&lt;br&gt;
Example: &lt;strong&gt;url &lt;a href="https://mysite.com/api/product/%7Bid%7D/item"&gt;https://mysite.com/api/product/{id}/item&lt;/a&gt;&lt;/strong&gt;. After it need create new line &lt;strong&gt;(Ctrl-Enter)&lt;/strong&gt; and type &lt;strong&gt;route id=some value&lt;/strong&gt;. Examples &lt;strong&gt;route id=10&lt;/strong&gt;, &lt;strong&gt;route id=8bfe1522–225d-4e30–8c8a-4a7c01209995&lt;/strong&gt;.&lt;br&gt;
Before the HTTP(s) request is made, the URL will be formatted and any defined dynamic segments will be replaced with the corresponding defined values. Full example:&lt;br&gt;
&lt;strong&gt;url &lt;a href="https://mysite.com/api/%7Bobjectid%7D/%7Bid%7D/item"&gt;https://mysite.com/api/{objectid}/{id}/item&lt;/a&gt;&lt;/strong&gt;&lt;br&gt;
&lt;strong&gt;route id=10&lt;/strong&gt;&lt;br&gt;
&lt;strong&gt;route objectid=product&lt;/strong&gt;&lt;br&gt;
In final it will be URL: &lt;strong&gt;&lt;a href="https://mysite.com/api/product/10/item"&gt;https://mysite.com/api/product/10/item&lt;/a&gt;&lt;/strong&gt;&lt;br&gt;
You can also use a segment with the same name more than once, in which case all segments will be replaced with the same corresponding value from the field. Example &lt;strong&gt;&lt;a href="https://mysite.com/api/%7Bid%7D/somepath/%7Bid%7D/prefix/%7Bid%7D"&gt;https://mysite.com/api/{id}/somepath/{id}/prefix/{id}&lt;/a&gt;&lt;/strong&gt;&lt;br&gt;
Of course you can combined route fields with other URL parameters in &lt;strong&gt;param&lt;/strong&gt; fields if you have complex URL.&lt;/p&gt;

&lt;h2&gt;
  
  
  Generating images
&lt;/h2&gt;

&lt;p&gt;For the most part, you work with one of the bug tracking systems (for example, JIRA) and there are times when you need to&lt;br&gt;
simply to share information about a request without a response, for example, to report the time it took to complete or an error in the request.&lt;br&gt;
Then you can generate an image containing the request settings, the contents of the summary section and the response headers as an image.&lt;br&gt;
To do this, you just need to press &lt;strong&gt;Ctrl-8&lt;/strong&gt; to save the result to a file and &lt;strong&gt;Alt-8&lt;/strong&gt; to save the result to the clipboard.&lt;br&gt;
The result might look something like the screenshot below.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--SLECs1Cq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rtnfua6vstvp7hlh8fx8.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--SLECs1Cq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rtnfua6vstvp7hlh8fx8.png" alt="Generated summary and headers" width="720" height="828"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  OpenAPI exporter
&lt;/h2&gt;

&lt;p&gt;If you need to work with a RESTful API and it supports the description in OpenAPI v3 format, then you can greatly simplify&lt;br&gt;
a life with the help of a new window in the application called “Export from OpenAPI”. In this window you can by specifying the URL address of the scheme and the base address, and generate all the fields of the request for its execution in the main application window. A small disclaimer, in the current version only JSON-based schemas are supported.&lt;br&gt;
Press the &lt;strong&gt;F6&lt;/strong&gt; button to open the “Export from OpenAPI” window.&lt;br&gt;
In the window, you need to fill in the fields “Scheme URL” (this is the address where the OpenAPI scheme of your service is located) and “Base URL” (this is the address for which the request will be generated).&lt;br&gt;
Then press &lt;strong&gt;Ctrl-Z&lt;/strong&gt; to load the schema and get a list of possible queries.&lt;br&gt;
When the list is received, you can select the request in the list and click on it. After clicking on the request, the export window will close&lt;br&gt;
and in the main window a new request will be created in which the fields from the previously selected request will be generated.&lt;br&gt;
If the list is too large, you can filter the list by entering the desired name in the Filter field. Filtering works by method, route and description, you can also enter multiple filters separated by a space e.g. “get Apples” will filter out all requests with a GET method and Apples in the route or description.&lt;br&gt;
The export window also has its own keyboard commands, the help for which is the same as in the main window opens with the &lt;strong&gt;F1&lt;/strong&gt; key. The scheme is loaded once and then you can return to the export window again for generating other requests to fulfill. In addition, you can save field settings and in further load them from the Saved Options tab. To save the current set of fields, press &lt;strong&gt;Ctrl-Insert&lt;/strong&gt;. If you want to save settings with a human readable name just put it in the “Title” field otherwise it will be given the same as “Scheme URL”.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--JJDu57e9--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/x9ayomupyqd2riyj0pl3.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--JJDu57e9--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/x9ayomupyqd2riyj0pl3.jpg" alt="OpenAPI window" width="702" height="632"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>testing</category>
      <category>webdev</category>
      <category>rest</category>
    </item>
  </channel>
</rss>
