<?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: Guilherme Neves</title>
    <description>The latest articles on DEV Community by Guilherme Neves (@guilhermeneves142).</description>
    <link>https://dev.to/guilhermeneves142</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%2F1020127%2F7ce60f82-edf7-4278-a3d3-779248284d0a.jpeg</url>
      <title>DEV Community: Guilherme Neves</title>
      <link>https://dev.to/guilhermeneves142</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/guilhermeneves142"/>
    <language>en</language>
    <item>
      <title>Vue router with typescript Part 2</title>
      <dc:creator>Guilherme Neves</dc:creator>
      <pubDate>Mon, 06 Feb 2023 11:53:31 +0000</pubDate>
      <link>https://dev.to/guilhermeneves142/vue-router-with-typescript-part-2-5532</link>
      <guid>https://dev.to/guilhermeneves142/vue-router-with-typescript-part-2-5532</guid>
      <description>&lt;p&gt;Before I start explaining how to use the vue router in a project, I'll explain what routes are and how they work for SPA users.&lt;/p&gt;




&lt;h2&gt;
  
  
  What is a SPA (Single Page Application)?
&lt;/h2&gt;

&lt;p&gt;SPA are web applications in which the user interacts in only one page, that is, when performing some action on the page it will not need to be completely reloaded.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;No SPA (No Single Page Application)&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3r571aaua1nrltqgabcm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3r571aaua1nrltqgabcm.png" alt="Image description" width="311" height="165"&gt;&lt;/a&gt;&lt;br&gt;
When an application is not a SPA and the user tries to go to the profile tab, the page is completely reloaded.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;SPA (Single Page Application)&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fgoqbi2drtaeau7lp7wga.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fgoqbi2drtaeau7lp7wga.png" alt="Image description" width="433" height="165"&gt;&lt;/a&gt;&lt;br&gt;
Twitter is a SPA application where when clicking on the profile or any other part of the page, the page will not be completely reloaded, but only what needs to be changed will be loaded, but for that it is necessary to configure a routing system.&lt;/p&gt;




&lt;h2&gt;
  
  
  Explanation Scenario
&lt;/h2&gt;

&lt;p&gt;Let's create a fictitious scenario where we have an application with a top menu with 3 options: Home, Users and Courses.&lt;/p&gt;

&lt;p&gt;When clicking on one of these three items, it is necessary to load a content below the menu according to what was clicked.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyf7t8nm5tf7nh8gqswwd.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyf7t8nm5tf7nh8gqswwd.png" alt="Image description" width="800" height="469"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Having known the scenario, the first thing we can realize is: "The menu will not change at any time". Knowing this then only the content must be changed, so this is a case where we can use routes.&lt;/p&gt;




&lt;h2&gt;
  
  
  What does vue-router do?
&lt;/h2&gt;

&lt;p&gt;Still using the scenario created and thinking only about using vue, what would you do? when clicking on a menu item the developer would show the corresponding component.&lt;/p&gt;

&lt;p&gt;With the use of vue-router in your project, this component modification logic is carried out by vue-router, in addition to being able to perform other functionalities such as: validations, route configurations and child routes (I will explain in the future).&lt;/p&gt;




&lt;p&gt;I'll be back soon to continue explaining about vue-router. Let me know what you think of the post and any questions you have.&lt;/p&gt;

&lt;p&gt;See you later.&lt;/p&gt;

</description>
      <category>gratitude</category>
      <category>community</category>
    </item>
    <item>
      <title>Vue router with typescript Part 1</title>
      <dc:creator>Guilherme Neves</dc:creator>
      <pubDate>Fri, 03 Feb 2023 13:35:35 +0000</pubDate>
      <link>https://dev.to/guilhermeneves142/vue-router-with-typescript-part-1-kj5</link>
      <guid>https://dev.to/guilhermeneves142/vue-router-with-typescript-part-1-kj5</guid>
      <description>&lt;p&gt;I've been finding a lot of people struggling with routes in vue where I work, so I decided to put together an article to clear up some doubts about routes.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why use routes in a project?
&lt;/h2&gt;

&lt;p&gt;Routes will help the user to create navigation where you can go from one page to another without needing to reload.&lt;/p&gt;

&lt;p&gt;Like any skill, it will take some effort and practice to master Vue Router.&lt;/p&gt;

&lt;h2&gt;
  
  
  How do I install vue router in my project?
&lt;/h2&gt;

&lt;p&gt;There are two ways to insert the vue router into a project.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;The first way is to create the project and in the initial setup select that you want to start the project with routes.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The second way is in an ongoing project. To install it in the project, run the command:&lt;br&gt;
&lt;strong&gt;NPM&lt;/strong&gt;&lt;br&gt;
&lt;code&gt;npm install vue-router@4&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;YARN&lt;/strong&gt;&lt;br&gt;
&lt;code&gt;yarn add vue-router@4&lt;/code&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Route configuration
&lt;/h2&gt;

&lt;p&gt;After installing vue router in the project, some files are created for you to configure your routes.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fsxuf2ok5vqx0zbyjtph0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fsxuf2ok5vqx0zbyjtph0.png" alt="Image description" width="703" height="480"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In this file we are going to perform most of the configurations related to routes in the project.&lt;/p&gt;

&lt;p&gt;Let me know what you think of this short introduction to vue router in the comments and if this is something you can use in your projects. I'll be back as soon as posible for part two, where I'll delve into route settings.&lt;/p&gt;

&lt;p&gt;Until later!&lt;/p&gt;

</description>
      <category>cryptocurrency</category>
      <category>blockchain</category>
      <category>web3</category>
      <category>ethereum</category>
    </item>
  </channel>
</rss>
