<?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: Lucas Vilaboim</title>
    <description>The latest articles on DEV Community by Lucas Vilaboim (@vilaboim).</description>
    <link>https://dev.to/vilaboim</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%2F59693%2Fac961cc1-3fe9-4a45-ac42-f6a3809c8046.jpeg</url>
      <title>DEV Community: Lucas Vilaboim</title>
      <link>https://dev.to/vilaboim</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/vilaboim"/>
    <language>en</language>
    <item>
      <title>O Descompasso entre Frontend e Backend: Por que suas Rotas Devem Ser RESTful</title>
      <dc:creator>Lucas Vilaboim</dc:creator>
      <pubDate>Thu, 11 Sep 2025 14:21:46 +0000</pubDate>
      <link>https://dev.to/vilaboim/o-descompasso-entre-frontend-e-backend-por-que-suas-rotas-devem-ser-restful-3i7f</link>
      <guid>https://dev.to/vilaboim/o-descompasso-entre-frontend-e-backend-por-que-suas-rotas-devem-ser-restful-3i7f</guid>
      <description>&lt;p&gt;Sabe quando você está construindo uma aplicação e de repente percebe que as URLs que o usuário navega na tela não têm muita conexão com as rotas da sua API? Por exemplo, o usuário acessa meusite.com/listar-artigos e, por baixo dos panos, o seu código faz uma requisição para a API em api.meusite.com/posts. A aplicação funciona, claro, mas essa pequena diferença esconde uma oportunidade enorme de deixar o seu código mais limpo e intuitivo.&lt;/p&gt;

&lt;p&gt;Aqui vamos explorar a ideia de alinhar a arquitetura de rotas do seu frontend com os princípios RESTful do backend. Não é uma regra rígida, mas uma abordagem que traz mais consistência, previsibilidade e, no fim das contas, facilita a vida de quem precisa dar manutenção no projeto.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;O Que é RESTful, de Fato?&lt;/strong&gt;&lt;br&gt;
Se você já trabalhou com APIs, é provável que já tenha ouvido falar em REST, ou mais especificamente, em RESTful. De forma bem simples, pense em um sistema RESTful como um conjunto de regras que guiam a comunicação entre o seu frontend e o backend. O ponto principal é que tudo é tratado como um recurso, e as ações que você pode fazer com esses recursos são definidas por &lt;strong&gt;verbos HTTP&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Não precisa de muita teoria. A regra de ouro é: uma URL deve identificar um recurso, e o verbo HTTP diz o que você quer fazer com ele. Por exemplo, em um blog:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;GET /posts&lt;/strong&gt;: Pede para "obter" (GET) a lista de todos os "posts".&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;GET /posts/123&lt;/strong&gt;: Pede para "obter" (GET) um "post" específico (o de ID 123).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;POST /posts&lt;/strong&gt;: Pede para "criar" (POST) um novo "post".&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;DELETE /posts/123&lt;/strong&gt;: Pede para "deletar" (DELETE) o "post" de ID 123.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Essa organização é o que nos permite ter rotas previsíveis no backend, algo que podemos e devemos espelhar no frontend.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;A Relação Direta: Sua URL no Navegador&lt;/strong&gt;&lt;br&gt;
A grande sacada aqui é a seguinte: a URL que o seu usuário vê no navegador, a URL que aparece na barra de endereços, pode — e deveria — ser um espelho da rota da API que está sendo consumida.&lt;/p&gt;

&lt;p&gt;Pense na experiência do usuário e na sua própria como desenvolvedor. Quando você vê a URL meublog.com/posts/123, o que você espera que aconteça? Você espera ver o post com o ID 123. E, por trás dessa interface, a sua aplicação de frontend pode estar fazendo uma requisição GET para a rota /posts/123 na sua API.&lt;/p&gt;

&lt;p&gt;Outro exemplo: quando você está em uma página de criação e a URL é meublog.com/posts/new, a ação esperada é criar um novo post. Por baixo dos panos, a sua aplicação provavelmente enviará uma requisição POST para a rota /posts.&lt;/p&gt;

&lt;p&gt;Essa não é uma coincidência; é uma prática de design intencional que traz clareza para todos os envolvidos. O usuário tem uma URL intuitiva e limpa, e o desenvolvedor tem uma rota no frontend que faz sentido e se alinha com o "contrato" da API. Essa previsibilidade é o que simplifica a vida de todo mundo.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Por que isso é uma Boa Ideia? Onde o "ganho" acontece?&lt;/strong&gt;&lt;br&gt;
Você pode estar se perguntando: "Ok, entendi o conceito, mas por que eu deveria me preocupar em fazer isso?". A resposta é simples: previsibilidade e clareza. Seguir esse padrão não é só uma questão de estética; é uma decisão de arquitetura que traz ganhos reais para o seu projeto e sua equipe.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Facilidade de Manutenção e Leitura&lt;/strong&gt;&lt;br&gt;
Ao alinhar as rotas do frontend com a API, você torna o seu código mais legível e intuitivo. Um novo desenvolvedor que entra no projeto e vê uma rota como /posts/:id no código do frontend já consegue deduzir imediatamente que ela está consumindo a API de GET /posts/:id. Essa clareza reduz a curva de aprendizado e minimiza a chance de erros.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Simplificação da Comunicação&lt;/strong&gt;&lt;br&gt;
Quando a rota do frontend espelha a da API, o "contrato" entre o front-end e o back-end se torna explícito. A URL do navegador é a documentação. Isso elimina a necessidade de longas reuniões ou documentos complexos para explicar como uma determinada tela se conecta com o servidor. A comunicação entre as equipes se torna mais fluida e natural.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Consistência e Previsibilidade&lt;/strong&gt;&lt;br&gt;
Pense em um Design System, mas para as URLs. Quando você segue um padrão, o comportamento do sistema se torna previsível. Você sabe que a rota para listar um recurso será sempre a sua URL no plural (/recursos), e a para ver o detalhe será com um identificador (/recursos/123). Essa consistência reduz o atrito e permite que a equipe se concentre em problemas mais complexos.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Exemplos Práticos: Da Teoria à Prática&lt;/strong&gt;&lt;br&gt;
Para visualizar como essa ideia funciona na prática, vamos voltar ao nosso exemplo do blog. Veja como a URL no navegador se alinha diretamente com a rota da API, tornando a comunicação e o entendimento do sistema muito mais fáceis.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Listar todos os posts:&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;URL no navegador:&lt;/strong&gt; meublog.com/posts&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Requisição à API:&lt;/strong&gt; GET /posts&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Visualizar um post específico:&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;URL no navegador:&lt;/strong&gt; meublog.com/posts/123&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Requisição à API:&lt;/strong&gt; GET /posts/123&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;strong&gt;Listar posts de um autor específico, ordenados do mais antigo para o mais novo:&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;URL no navegador:&lt;/strong&gt; meublog.com/posts?author=vilaboim&amp;amp;order=older&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Requisição à API:&lt;/strong&gt; GET /posts?author=vilaboim&amp;amp;order=older&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;Percebe como a consistência simplifica o processo? Ao ver a URL no navegador, você já sabe exatamente qual requisição a sua aplicação de frontend precisa fazer para interagir com o backend.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Conclusão: Um Pequeno Passo para uma Grande Melhoria&lt;/strong&gt;&lt;br&gt;
Alinhar as rotas do seu frontend com a arquitetura RESTful do backend pode parecer um detalhe pequeno, quase uma formalidade. Mas, como vimos, essa simples prática tem um impacto significativo na saúde do seu projeto.&lt;/p&gt;

&lt;p&gt;Não é seguir regras por seguir, mas construir sistemas mais previsíveis, fáceis de entender e, consequentemente, mais fáceis de manter. Quando as URLs no navegador fazem sentido e espelham a API, você está criando um "contrato" de navegação intuitivo, simplificando a vida de quem usa e, principalmente, de quem desenvolve.&lt;/p&gt;

&lt;p&gt;Da próxima vez que você for criar as rotas para o seu projeto, pense nisso. Esse pequeno ajuste de arquitetura pode fazer uma grande diferença na colaboração da sua equipe e na longevidade do seu código.&lt;/p&gt;

</description>
      <category>braziliandevs</category>
      <category>frontend</category>
      <category>rest</category>
      <category>dx</category>
    </item>
    <item>
      <title>Guide to using Slack in remote work</title>
      <dc:creator>Lucas Vilaboim</dc:creator>
      <pubDate>Sat, 24 Feb 2024 00:54:13 +0000</pubDate>
      <link>https://dev.to/villageboim/guide-to-using-slack-in-remote-work-3457</link>
      <guid>https://dev.to/villageboim/guide-to-using-slack-in-remote-work-3457</guid>
      <description>&lt;p&gt;📸 by &lt;a href="https://unsplash.com/photos/minimalist-photography-of-three-crank-phones-71CjSSB83Wo" rel="noopener noreferrer"&gt;Pavan Trikutam&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  The secret is asynchronous communication
&lt;/h2&gt;

&lt;p&gt;Asynchronous communication is when you communicate without expecting an immediate response. And this allows you to do your work in a more concentrated manner and with fewer interruptions, which is very important in remote work.&lt;/p&gt;

&lt;p&gt;The aim of this guide is for you to interrupt less and be less interrupted in the remote work environment, and it starts from the principle that all communication can and should be asynchronous.&lt;/p&gt;

&lt;h3&gt;
  
  
  How do I do this?
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Could this meeting be an email, a message, an audio, a video? Yes.&lt;/li&gt;
&lt;li&gt;And using one of these options, would the problem be solved quickly and effectively? Yes.&lt;/li&gt;
&lt;li&gt;So I'll use one of the aforementioned substitutions.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  How to make your conversations asynchronous
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Can your message be understood with just text? Send a message.&lt;/li&gt;
&lt;li&gt;Is it more complex and requires more context? Send an audio.&lt;/li&gt;
&lt;li&gt;Is there a need to present a screen? Send a video.&lt;/li&gt;
&lt;li&gt;Need a deeper discussion with exchange of ideas? Then a meeting can be useful.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;💡&lt;em&gt;Tip:&lt;/em&gt; don't just send &lt;strong&gt;Hi, how are you?&lt;/strong&gt;, complement with what you need;&lt;br&gt;
💡&lt;em&gt;Tip 2:&lt;/em&gt; if you received the &lt;strong&gt;Hi, how are you? I need X&lt;/strong&gt;, assume the good intention of the person who sent you this beautiful asynchronous message;&lt;br&gt;
💡&lt;em&gt;Tip 3:&lt;/em&gt; if sending audio or video, also send a title so the person can search in the future.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;code&gt;@channel&lt;/code&gt; and &lt;code&gt;@here&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Using channels in Slack reduces noise and communicates a lot of people at once, but a communication error in a channel, involving many people, can cause a lot of embarrassment.&lt;/p&gt;

&lt;p&gt;Imagine you work in a room with over 20 people, and you need to pass on a message. You could stand in front of the door and get everyone's attention, when everyone looks, you speak. But imagine if this repeats several times a week, or even in one day, it would be impractical to stop everyone every time; in such a situation, I would simply put a notice on the door, and whoever passes by will see it and eventually comment to other colleagues.&lt;/p&gt;

&lt;p&gt;And the remote environment works similarly, when we tag a message with &lt;code&gt;@here&lt;/code&gt; we notify everyone who is online on Slack, and with &lt;code&gt;@channel&lt;/code&gt; it's worse because we notify even those who are offline - people on vacation, on leave, getting married - and if people respond in the thread it's a notification for each message.&lt;/p&gt;

&lt;h3&gt;
  
  
  I follow these rules:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Does everyone need to read the message at the moment it will be sent? If the answer is no, I &lt;strong&gt;do not&lt;/strong&gt; use &lt;code&gt;@here&lt;/code&gt; or &lt;code&gt;@channel&lt;/code&gt;;&lt;/li&gt;
&lt;li&gt;Okay, the message is very important and immediate, but will only benefit or help those who are online? I send an &lt;code&gt;@here&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;And as a &lt;strong&gt;last resort&lt;/strong&gt;, when I couldn't find a justification not to notify everyone, I review my life choices, but never send &lt;code&gt;@channel&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;You can learn more about notifications &lt;a href="https://slack.com/help/articles/202009646-Notify-a-channel-or-workspace" rel="noopener noreferrer"&gt;here&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Direct Messages vs Group Messages vs Channels
&lt;/h2&gt;

&lt;p&gt;Slack allows you to chat with one or more people in three ways:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;A conversation between 2 people, which is a direct message;&lt;/li&gt;
&lt;li&gt;A conversation between 3 or more people through a channel;&lt;/li&gt;
&lt;li&gt;And a conversation between 3 or more people through a group direct message;&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  When to use a direct message
&lt;/h3&gt;

&lt;p&gt;Want to talk to just one person and the subject doesn't need to involve more people? Send a direct message.&lt;/p&gt;

&lt;h3&gt;
  
  
  When to use a group direct message
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Does this conversation have between 3 and 9 people?&lt;/li&gt;
&lt;li&gt;Does it have a deadline to finish? Is it a specific topic?&lt;/li&gt;
&lt;li&gt;Will no one else be added to the conversation?&lt;/li&gt;
&lt;li&gt;Answered Yes to &lt;strong&gt;all&lt;/strong&gt; questions? Use the group direct message.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  When to use channels?
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Does this conversation have more than 9 people?&lt;/li&gt;
&lt;li&gt;Will new people be added over time?&lt;/li&gt;
&lt;li&gt;Is it a subject that will be prolonged or revisited several times?&lt;/li&gt;
&lt;li&gt;Answered Yes to &lt;strong&gt;any&lt;/strong&gt; of these questions? Create a channel.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;&lt;a href="https://slack.com/help/categories/200111606#direct-messages" rel="noopener noreferrer"&gt;Here&lt;/a&gt; you'll find more information about direct messages, and &lt;a href="https://slack.com/help/categories/200111606#channels" rel="noopener noreferrer"&gt;here&lt;/a&gt; about channels.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Threads
&lt;/h2&gt;

&lt;p&gt;Channels are great for sharing conversations, but when a discussion extends too much, it becomes almost impossible to know when it starts or ends.&lt;/p&gt;

&lt;p&gt;For those familiar with Twitter, Slack threads are quite similar; for those who don't, it's more or less like this:&lt;/p&gt;

&lt;p&gt;There's the timeline of messages, whether in direct messages or channels, with the entire history of messages sent there; a thread is a way to organize only the responses related to a specific message.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Let's look at an example:&lt;/strong&gt; I send a message about the company website not working, immediately after my message someone asks how to access a certain database, and after this message someone else responds to my message, asking for more details of my problem, and with a few more messages the conversations get mixed up and it's difficult to follow and know where one starts and the other ends.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;And now this same situation with threads:&lt;/strong&gt; I send my message, someone sends another about a different topic, a third person asks me for more details, but this time within the thread of my message, and so the two subjects evolve, each in its thread, without cluttering the original timeline and facilitating future search.&lt;/p&gt;

&lt;p&gt;💡&lt;em&gt;Tip:&lt;/em&gt; need to send a message in an old thread and want new people (besides those who responded to the thread) to know? Check the box below the message and send it to the channel or group direct message.&lt;/p&gt;

&lt;p&gt;More information about threads &lt;a href="https://slack.com/help/articles/115000769927-Use-threads-to-organize-discussions-" rel="noopener noreferrer"&gt;here&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Audios and Huddles
&lt;/h2&gt;

&lt;p&gt;When we have a very complex concept or problem to be sent and solved via text, we resort to a meeting with too many people, without purpose, and that only generates another meeting. We can simplify this flow with Slack audios and huddles, with these conditions:&lt;/p&gt;

&lt;h3&gt;
  
  
  When to send an audio
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Do you just need to communicate (without the need for discussion) something more complex?&lt;/li&gt;
&lt;li&gt;Do you just need to explain a concept or problem to one or more people?&lt;/li&gt;
&lt;li&gt;Answered Yes to &lt;strong&gt;any&lt;/strong&gt; of these questions? Send an audio.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  When to create a huddle
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Do you need to discuss an idea, a concept, or outline a strategy with one or more people?
Answered Yes, create a huddle.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;💡&lt;em&gt;Tip:&lt;/em&gt; remember, a good meeting is a meeting with a goal; if you need to create a huddle, have a goal and an end time for the meeting, and take the lead in the discussion to ensure that both points will be achieved: solving the issue within the set time.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://slack.com/help/categories/200111606#audio-video" rel="noopener noreferrer"&gt;Here&lt;/a&gt; is Slack's documentation on audio and video.&lt;/p&gt;

</description>
      <category>slack</category>
      <category>braziliandevs</category>
      <category>remote</category>
    </item>
    <item>
      <title>Basic guide to code review</title>
      <dc:creator>Lucas Vilaboim</dc:creator>
      <pubDate>Sat, 24 Feb 2024 00:09:03 +0000</pubDate>
      <link>https://dev.to/villageboim/basic-guide-to-code-review-f6g</link>
      <guid>https://dev.to/villageboim/basic-guide-to-code-review-f6g</guid>
      <description>&lt;p&gt;A software developer will have their code reviewed and will review others' code practically every day, and even with this repetition, sometimes we forget a point or two.&lt;/p&gt;

&lt;p&gt;This is a guide with basic points to be checked in a code review, feel free to use/modify/improve it, in your company or open-source project.&lt;/p&gt;

&lt;h2&gt;
  
  
  For the requester
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Write good commit messages (following the &lt;a href="https://www.conventionalcommits.org/en/v1.0.0/" rel="noopener noreferrer"&gt;Conventional Commits&lt;/a&gt; is a good start);&lt;/li&gt;
&lt;li&gt;Review your pull request before opening it, make sure you haven't forgotten any debugger or typing error;&lt;/li&gt;
&lt;li&gt;Keep your pull request small, this makes it easy to review and less harmful to the business;&lt;/li&gt;
&lt;li&gt;Ensure that your pull request passes tests, linters, and builds, and has no conflicts;&lt;/li&gt;
&lt;li&gt;Write a good description;&lt;/li&gt;
&lt;li&gt;Comment on your own pull request if any piece of code is not obvious;&lt;/li&gt;
&lt;li&gt;Wait for the reviewer to finish before starting to fix;&lt;/li&gt;
&lt;li&gt;Choose the right reviewers (example: someone who has already worked on the same part of the code);&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  For the reviewer
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Be kind;&lt;/li&gt;
&lt;li&gt;Be a thorough person (this &lt;a href="https://www.morling.dev/blog/the-code-review-pyramid/" rel="noopener noreferrer"&gt;document&lt;/a&gt; can help you);&lt;/li&gt;
&lt;li&gt;Seek context. Read the pull request description, the ticket, even check the screens (if any);&lt;/li&gt;
&lt;li&gt;Make sure you've set aside the necessary time to understand and make the best code review you can;&lt;/li&gt;
&lt;li&gt;Respect the context. If a pull request fixes a bug, don't ask the developer to refactor the entire component, this can be addressed in the future;&lt;/li&gt;
&lt;li&gt;Make it clear that you are doing the review, comment &lt;em&gt;Reviewing&lt;/em&gt; when starting, and &lt;em&gt;Reviewed&lt;/em&gt; when finished.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;This guide is constantly evolving&lt;/strong&gt; 😊&lt;/p&gt;

</description>
      <category>codereview</category>
      <category>dx</category>
      <category>braziliandevs</category>
    </item>
    <item>
      <title>Guia de uso do Slack no trabalho remoto</title>
      <dc:creator>Lucas Vilaboim</dc:creator>
      <pubDate>Wed, 29 Nov 2023 12:10:10 +0000</pubDate>
      <link>https://dev.to/vilaboim/guia-de-uso-do-slack-no-trabalho-remoto-1cpp</link>
      <guid>https://dev.to/vilaboim/guia-de-uso-do-slack-no-trabalho-remoto-1cpp</guid>
      <description>&lt;p&gt;📸 por &lt;a href="https://unsplash.com/photos/minimalist-photography-of-three-crank-phones-71CjSSB83Wo" rel="noopener noreferrer"&gt;Pavan Trikutam&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  O segredo é a comunicação assíncrona
&lt;/h2&gt;

&lt;p&gt;Comunicação assíncrona é quando se comunica sem esperar resposta imediata. E isso te possibilita fazer seu trabalho de forma mais concentrada e sem muitas interrupções, o que é muito importante no trabalho remoto.&lt;/p&gt;

&lt;p&gt;O objetivo deste guia é que você interrompa menos e seja menos interrompido no ambiente de trabalho remoto, e ele parte do princípio de que toda comunicação pode e deve ser assíncrona.&lt;/p&gt;

&lt;h3&gt;
  
  
  Como faço isso?
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Essa reunião poderia ser um e-mail, uma mensagem, um áudio, um vídeo? Sim.&lt;/li&gt;
&lt;li&gt;E usando uma dessas opções o problema seria resolvido de forma rápida e efetiva? Sim.&lt;/li&gt;
&lt;li&gt;Então usarei uma das substituições acima mencionadas.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Como tornar as suas conversas assíncronas
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Sua mensagem pode ser compreendida apenas com texto? Mande uma mensagem.&lt;/li&gt;
&lt;li&gt;Ela é mais complexa e necessita de mais contexto? Mande um áudio.&lt;/li&gt;
&lt;li&gt;Há a necessidade de apresentar alguma tela? Mande um vídeo.&lt;/li&gt;
&lt;li&gt;Precisa de uma discussão mais aprofundada com troca de ideias? Aí sim uma reunião pode ser útil.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;💡&lt;em&gt;Dica:&lt;/em&gt; não mande apenas &lt;strong&gt;Oi, tudo bem?&lt;/strong&gt;, complemente com o que você precisa;&lt;br&gt;
💡&lt;em&gt;Dica 2:&lt;/em&gt; você que recebeu o &lt;strong&gt;Oi, tudo bem? Preciso de X&lt;/strong&gt;, assuma a boa intenção de quem te enviou essa bela mensagem assíncrona;&lt;br&gt;
💡&lt;em&gt;Dica 3:&lt;/em&gt; se for mandar áudio ou vídeo envie também um título para a pessoa poder fazer uma busca no futuro.&lt;/p&gt;

&lt;h2&gt;
  
  
  @canal and @aqui
&lt;/h2&gt;

&lt;p&gt;O uso de canais no Slack diminui ruídos e comunica muita gente de uma vez só, mas um erro de comunicação em um canal, por envolver muitas pessoas, pode causar muitos constrangimentos. &lt;/p&gt;

&lt;p&gt;Imagine que você trabalhe presencialmente em uma sala com mais 20 pessoas, e você precisa dar um recado. Você pode parar na frente da porta e chamar a atenção de todos, quando todas as pessoas olharem, você fala. Mas imagine que isso se repete algumas vezes na semana, ou em um só dia, ficaria inviável parar todo mundo todas essas vezes, se eu estivesse nessa situação apenas colocaria um aviso na porta e quem passar por ali verá e acabará comentando com outros colegas.&lt;/p&gt;

&lt;p&gt;E o ambiente remoto funciona de forma parecida, quando marcamos uma mensagem com &lt;strong&gt;@aqui&lt;/strong&gt; notificamos todas as pessoas que estão on-line no Slack, e com o &lt;strong&gt;@canal&lt;/strong&gt; é pior, pois notificamos até quem não está on-line - pessoas de férias, de licença, que estão se casando - e se pessoas respondem na thread é uma notificação para cada mensagem.&lt;/p&gt;

&lt;h3&gt;
  
  
  Eu sigo as seguintes regras:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Todo mundo precisa ler a mensagem no momento que ela será enviada? Se a resposta for não, eu &lt;strong&gt;não&lt;/strong&gt; uso @aqui ou @canal;&lt;/li&gt;
&lt;li&gt;Ok, a mensagem é muito importante e imediata, mas só fará proveito ou poderá me ajudar quem estiver on-line? Mando um @aqui.&lt;/li&gt;
&lt;li&gt;E em &lt;strong&gt;último caso&lt;/strong&gt;, quando eu não consegui achar uma justificativa para não avisar todo mundo, eu revejo minhas escolhas de vida, mas nunca mando @canal.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Você pode aprender mais sobre notificações &lt;a href="https://slack.com/intl/pt-br/help/articles/202009646-Notificar-um-canal-ou-workspace" rel="noopener noreferrer"&gt;aqui&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Mensagens diretas vs mensagens em grupo vs canais
&lt;/h2&gt;

&lt;p&gt;O Slack te permite conversar com uma ou mais pessoas de três maneiras:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;A conversa entre 2 pessoas, que é uma mensagem direta;&lt;/li&gt;
&lt;li&gt;A conversa entre 3 ou mais pessoas por um canal;&lt;/li&gt;
&lt;li&gt;E a conversa entre 3 ou mais pessoas por uma mensagem direta em grupo;&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Quando usar uma mensagem direta
&lt;/h3&gt;

&lt;p&gt;Quer conversar com apenas uma pessoa e o assunto não precisa ser tratado por mais pessoas? Mande uma mensagem direta.&lt;/p&gt;

&lt;h3&gt;
  
  
  Quando usar uma mensagem direta em grupo
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Esta conversa tem entre 3 e 9 pessoas?&lt;/li&gt;
&lt;li&gt;Ela tem prazo para se encerrar? É um assunto pontual?&lt;/li&gt;
&lt;li&gt;Mais ninguém será adicionado à conversa?&lt;/li&gt;
&lt;li&gt;Respondeu Sim a &lt;strong&gt;todas&lt;/strong&gt; as perguntas? Use a mensagem direta em grupo.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Quando usar canais?
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Esta conversa tem mais de 9 pessoas?&lt;/li&gt;
&lt;li&gt;Novas pessoas serão adicionadas com o tempo?&lt;/li&gt;
&lt;li&gt;É um assunto que se prolongará ou será retomado várias vezes?&lt;/li&gt;
&lt;li&gt;Respondeu Sim a &lt;strong&gt;alguma&lt;/strong&gt; dessas perguntas? Crie um canal.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;&lt;a href="https://slack.com/intl/pt-br/help/categories/200111606#mensagens-diretas" rel="noopener noreferrer"&gt;Aqui&lt;/a&gt; você encontra mais informações sobre mensagens diretas, e &lt;a href="https://slack.com/intl/pt-br/help/categories/200111606#canais" rel="noopener noreferrer"&gt;aqui&lt;/a&gt; sobre canais.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Threads
&lt;/h2&gt;

&lt;p&gt;Canais são ótimos para compartilhar conversas, mas quando uma discussão rende muito assunto fica quase impossível saber quando ela começa ou termina.&lt;/p&gt;

&lt;p&gt;Para você que conhece o Twitter, as &lt;em&gt;threads&lt;/em&gt; do Slack são bem parecidas, para quem não conhece, é mais ou menos assim:&lt;/p&gt;

&lt;p&gt;Existe a &lt;em&gt;timeline&lt;/em&gt; de mensagens, seja em mensagens diretas ou canais, com todo histórico de mensagens enviadas ali, uma thread é uma forma de organizar somente as respostas relativas a uma determinada mensagem.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Vamos a um exemplo:&lt;/strong&gt; eu mando uma mensagem sobre o site da empresa não estar funcionando, imediatamente após minha mensagem alguém pergunta como acessar um determinado banco de dados, e depois desta mensagem outro alguém responde a minha mensagem, perguntando por mais detalhes do meu problema, e com mais algumas mensagens as conversas se misturam e fica difícil acompanhar e saber onde uma começa e a outra termina.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;E agora essa mesma situação com &lt;em&gt;threads&lt;/em&gt;:&lt;/strong&gt; eu mando minha mensagem, alguém manda outra sobre outro assunto, uma terceira pessoa me pede mais detalhes, mas desta vez dentro da &lt;em&gt;thread&lt;/em&gt; da minha mensagem, e assim os dois assuntos evoluem, cada uma na sua &lt;em&gt;thread&lt;/em&gt;, sem sujar a &lt;em&gt;timeline&lt;/em&gt; original e facilitando a busca no futuro.&lt;/p&gt;

&lt;p&gt;💡&lt;em&gt;Dica:&lt;/em&gt; precisa mandar mensagem numa &lt;em&gt;thread&lt;/em&gt; antiga e quer que novas pessoas (além de quem respondeu à &lt;em&gt;thread&lt;/em&gt;) saibam? Marque a caixa abaixo da mensagem e envie-a ao canal ou mensagem direta em grupo.&lt;/p&gt;

&lt;p&gt;Mais informações sobre &lt;em&gt;threads&lt;/em&gt; &lt;a href="https://slack.com/intl/pt-br/help/articles/115000769927-Usar-conversas-para-organizar-as-discuss%C3%B5es-" rel="noopener noreferrer"&gt;aqui&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Áudios e Círculos
&lt;/h2&gt;

&lt;p&gt;Quando temos um conceito ou problema muito complexo para ser enviado e resolvido via texto apelamos para uma reunião com gente demais, sem objetivo e que só gera outra reunião. Podemos simplificar esse fluxo com os áudios e círculos (&lt;em&gt;huddles&lt;/em&gt;) do Slack, com essas condições:&lt;/p&gt;

&lt;h3&gt;
  
  
  Quando enviar um áudio
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Precisa apenas comunicar (sem a necessidade de discussão) algo mais complexo?&lt;/li&gt;
&lt;li&gt;Precisa apenas explicar um conceito ou problema para uma ou mais pessoas?&lt;/li&gt;
&lt;li&gt;Respondeu Sim a &lt;strong&gt;alguma&lt;/strong&gt; dessas perguntas? Envie um áudio.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Quando criar um círculo
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Precisa discutir uma ideia, um conceito ou traçar uma estratégia com uma ou mais pessoas?
Respondeu Sim, crie um círculo.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;💡&lt;em&gt;Dica:&lt;/em&gt; lembre-se, reunião boa é reunião com objetivo, se precisar criar um círculo tenha um objetivo e um horário de fim da reunião, e tome a frente da discussão para garantir que os dois pontos serão alcançados: resolver a questão dentro do tempo determinado.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://slack.com/intl/pt-br/help/categories/200111606#u225udio-e-vu237deo" rel="noopener noreferrer"&gt;Aqui&lt;/a&gt; está a documentação do Slack sobre áudio e vídeo.&lt;/p&gt;

</description>
      <category>slack</category>
      <category>braziliandevs</category>
      <category>remote</category>
    </item>
    <item>
      <title>Cuidado com o margin collapse</title>
      <dc:creator>Lucas Vilaboim</dc:creator>
      <pubDate>Thu, 28 Sep 2023 18:05:25 +0000</pubDate>
      <link>https://dev.to/vilaboim/cuidado-com-o-margin-collapse-3gbo</link>
      <guid>https://dev.to/vilaboim/cuidado-com-o-margin-collapse-3gbo</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;tldr:&lt;/strong&gt; Use margens em uma só direção, de preferência, para baixo.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Em elementos em sequência a margin-bottom do primeiro elemento e a margin-top do segundo elemento se colapsam e o menor valor é ignorado. Se você tem &lt;code&gt;margin-bottom: 10px&lt;/code&gt; e &lt;code&gt;margin-top: 5px&lt;/code&gt; isso não resultará em 15px de distância entre os elementos, mas sim 10px.&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%2F4rlbrt646ighptp1p55e.gif" 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%2F4rlbrt646ighptp1p55e.gif" alt="Exemplo do margin collapse usando a devtools do Chrome" width="382" height="156"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Resolver isso uma vez ou outra é tranquilo, mas pense em várias telas, com tabelas, listas, menus, etc.&lt;/p&gt;

&lt;p&gt;Usando as margens sempre em uma direção você elimina esse problema e ainda facilita a manutenção e integração com outros elementos do código.&lt;/p&gt;

&lt;p&gt;Dê uma olhada no exemplo abaixo.&lt;/p&gt;

&lt;p&gt;&lt;iframe src="https://codesandbox.io/embed/margin-collapsing-5yflks?module=%2Fsrc%2Fstyle.css"&gt;
&lt;/iframe&gt;
&lt;/p&gt;

&lt;p&gt;Se quiser mais detalhes confira o &lt;a href="https://mzl.la/3t40E6M" rel="noopener noreferrer"&gt;artigo&lt;/a&gt; no MDN.&lt;/p&gt;

</description>
      <category>css</category>
      <category>frontend</category>
      <category>braziliandevs</category>
    </item>
    <item>
      <title>Guia básico da revisão de código</title>
      <dc:creator>Lucas Vilaboim</dc:creator>
      <pubDate>Mon, 18 Sep 2023 21:41:12 +0000</pubDate>
      <link>https://dev.to/vilaboim/guia-basico-da-revisao-de-codigo-202k</link>
      <guid>https://dev.to/vilaboim/guia-basico-da-revisao-de-codigo-202k</guid>
      <description>&lt;p&gt;Uma pessoa que desenvolve software terá o seu código revisado e revisará o de outras pessoas praticamente todos os dias, e mesmo com essa repetição às vezes esquecemos um ponto ou outro.&lt;br&gt;
Este é um guia com pontos básicos a serem verificados em uma revisão de código, fique à vontade para usar/modificar/melhorar, na sua empresa ou projeto open source.&lt;/p&gt;

&lt;h2&gt;
  
  
  Para quem solicita
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Escreva boas mensagens de commit (seguir o &lt;a href="https://www.conventionalcommits.org/en/v1.0.0/" rel="noopener noreferrer"&gt;Conventional Commits&lt;/a&gt; é um bom início);&lt;/li&gt;
&lt;li&gt;Revise seu pull request antes de abrí-lo, tenha certeza que você não esqueceu algum debugger ou erro de digitação;&lt;/li&gt;
&lt;li&gt;Deixe seu pull request pequeno, isso o mantém fácil de revisar e menos nocivo ao negócio;&lt;/li&gt;
&lt;li&gt;Garanta que seu pull request passe nos testes, linters e builds, e não tenha conflitos;&lt;/li&gt;
&lt;li&gt;Escreva uma boa descrição;&lt;/li&gt;
&lt;li&gt;Comente no seu próprio pull request caso algum trecho de código não seja óbvio;&lt;/li&gt;
&lt;li&gt;Espere o revisor terminar para começar a corrigir;&lt;/li&gt;
&lt;li&gt;Escolha os revisores corretos (exemplo: alguém que já tenha trabalhado na mesma parte do código);&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Para quem revisa
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Seja gentil;&lt;/li&gt;
&lt;li&gt;Seja uma pessoa minuciosa (este &lt;a href="https://www.morling.dev/blog/the-code-review-pyramid/" rel="noopener noreferrer"&gt;documento&lt;/a&gt; pode te ajudar);&lt;/li&gt;
&lt;li&gt;Busque contexto. Leia a descrição do pull request, o ticket, verifique até mesmo as telas (se houver);&lt;/li&gt;
&lt;li&gt;Tenha certeza que você separou tempo necessário para entender e fazer a melhor revisão de código que você puder;&lt;/li&gt;
&lt;li&gt;Respeite o contexto. Se um pull request resolve um bug, não peça para a pessoa desenvolvedora refatorar todo o componente, isso pode ser resolvido no futuro;&lt;/li&gt;
&lt;li&gt;Deixe claro que você está fazendo a revisão, comente &lt;em&gt;Revisando&lt;/em&gt; ao iniciar, e &lt;em&gt;Revisado&lt;/em&gt; ao terminar.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Esse guia é vivo e está em constante evolução&lt;/strong&gt; 😉&lt;/p&gt;

</description>
      <category>codereview</category>
      <category>dx</category>
      <category>braziliandevs</category>
    </item>
    <item>
      <title>Register Global components in Vue 3</title>
      <dc:creator>Lucas Vilaboim</dc:creator>
      <pubDate>Fri, 07 May 2021 21:57:24 +0000</pubDate>
      <link>https://dev.to/vilaboim/register-global-components-in-vue-3-4n2c</link>
      <guid>https://dev.to/vilaboim/register-global-components-in-vue-3-4n2c</guid>
      <description>&lt;p&gt;&lt;strong&gt;UPDATE&lt;/strong&gt;: there is an &lt;a href="https://vuejs.org/guide/components/registration.html#global-registration" rel="noopener noreferrer"&gt;official guide&lt;/a&gt; now.&lt;/p&gt;

&lt;p&gt;Vue 2 docs has a great &lt;a href="https://vuejs.org/v2/guide/components-registration.html#Automatic-Global-Registration-of-Base-Components" rel="noopener noreferrer"&gt;way&lt;/a&gt; to automatically register base components.&lt;br&gt;
Fortunately this keeps working in Vue 3 with minimal changes.&lt;/p&gt;
&lt;h2&gt;
  
  
  Get started
&lt;/h2&gt;

&lt;p&gt;As soon as we start a project using vue-cli and Vue 3 we will see something like this in the &lt;code&gt;main.js&lt;/code&gt; file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nf"&gt;createApp&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;App&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;mount&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;#app&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Let's change it up a bit to add our base components:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;app&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;createApp&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;App&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;mount&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;#app&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Before &lt;strong&gt;mount&lt;/strong&gt; the app we will add our registration.&lt;/p&gt;

&lt;p&gt;Here we require all components that are inside &lt;code&gt;components&lt;/code&gt; folder:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;requireComponent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;require&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;context&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;./components&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="sr"&gt;/Base&lt;/span&gt;&lt;span class="se"&gt;[&lt;/span&gt;&lt;span class="sr"&gt;A-Z&lt;/span&gt;&lt;span class="se"&gt;]\w&lt;/span&gt;&lt;span class="sr"&gt;+.&lt;/span&gt;&lt;span class="se"&gt;(&lt;/span&gt;&lt;span class="sr"&gt;vue|js&lt;/span&gt;&lt;span class="se"&gt;)&lt;/span&gt;&lt;span class="sr"&gt;$/&lt;/span&gt;
&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If you prefer to have &lt;code&gt;folders&lt;/code&gt; and &lt;code&gt;index.vue&lt;/code&gt; files for components you need to change the regex:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="nx"&gt;Base&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;A&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="nx"&gt;Z&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="err"&gt;\&lt;/span&gt;&lt;span class="nx"&gt;w&lt;/span&gt;&lt;span class="o"&gt;+&lt;/span&gt;&lt;span class="err"&gt;\&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="nx"&gt;index&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;vue$&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Finally, you need to iterate over all components and register them using the Vue instance we assigned to &lt;code&gt;app&lt;/code&gt; variable:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;requireComponent&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;keys&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nf"&gt;forEach&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;fileName&lt;/span&gt; &lt;span class="o"&gt;=&amp;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;componentConfig&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;requireComponent&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;fileName&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;componentName&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;upperFirst&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="nf"&gt;camelCase&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
      &lt;span class="nx"&gt;fileName&lt;/span&gt;
        &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;split&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;/&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="nf"&gt;pop&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
        &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;replace&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sr"&gt;/&lt;/span&gt;&lt;span class="se"&gt;\.\w&lt;/span&gt;&lt;span class="sr"&gt;+$/&lt;/span&gt;&lt;span class="p"&gt;,&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="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;component&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="nx"&gt;componentName&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nx"&gt;componentConfig&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="nx"&gt;componentConfig&lt;/span&gt;
  &lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;})&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Is this real life?
&lt;/h2&gt;

&lt;p&gt;There is a &lt;a href="https://github.com/vilaboim/vue-3-global-registration" rel="noopener noreferrer"&gt;demo app&lt;/a&gt; to show the real life implementation.&lt;/p&gt;

</description>
      <category>vue</category>
      <category>javascript</category>
    </item>
  </channel>
</rss>
