<?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: Horus Lugo</title>
    <description>The latest articles on DEV Community by Horus Lugo (@horusgoul).</description>
    <link>https://dev.to/horusgoul</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%2F210860%2Fa7422269-8da7-4bb8-9d87-e7deb7eb1dca.jpeg</url>
      <title>DEV Community: Horus Lugo</title>
      <link>https://dev.to/horusgoul</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/horusgoul"/>
    <language>en</language>
    <item>
      <title>Use React Native Web's Pressable with Remix's Link magic</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Sat, 19 Feb 2022 13:09:59 +0000</pubDate>
      <link>https://dev.to/horusgoul/use-react-native-webs-pressable-with-remixs-link-magic-207i</link>
      <guid>https://dev.to/horusgoul/use-react-native-webs-pressable-with-remixs-link-magic-207i</guid>
      <description>&lt;p&gt;I just released &lt;a href="https://github.com/HorusGoul/remix-react-native-pressable"&gt;&lt;code&gt;remix-react-native-pressable&lt;/code&gt;&lt;/a&gt;, a small package that allows you to use React Native Web's &lt;code&gt;&amp;lt;Pressable&amp;gt;&lt;/code&gt; component with all of Remix's &lt;code&gt;&amp;lt;Link&amp;gt;&lt;/code&gt; properties and magic.&lt;/p&gt;

&lt;p&gt;Essentially, it implements the same logic Remix uses in their &lt;code&gt;&amp;lt;Link&amp;gt;&lt;/code&gt;, but adapted to React Native Web's &lt;code&gt;&amp;lt;Pressable&amp;gt;&lt;/code&gt; props.&lt;/p&gt;

&lt;p&gt;Here's a little example using the &lt;code&gt;to&lt;/code&gt; property:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;View&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;Text&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;react-native&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;RemixPressable&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;remix-react-native-pressable&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&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="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;MyRemixRoute&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;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;View&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;RemixPressable&lt;/span&gt; &lt;span class="na"&gt;to&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"/about"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Text&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;Link to /about&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;Text&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;RemixPressable&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;View&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&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;p&gt;Just like that, you get a link rendered using &lt;code&gt;&amp;lt;RemixPressable&amp;gt;&lt;/code&gt;. The main benefit of this is that you can now use this component like any other React Native Web's &lt;code&gt;&amp;lt;Pressable&amp;gt;&lt;/code&gt; you have in your app.&lt;/p&gt;

&lt;p&gt;Here's another example (extracted from my website's rewrite!), in which you can see another way of using this library. I have a design system with a Button that uses &lt;code&gt;&amp;lt;Pressable&amp;gt;&lt;/code&gt; in its implementation, but the design system is platform agnostic, so it doesn't know about Remix. For cases like this, we can use the &lt;code&gt;&amp;lt;RemixPressableChildren&amp;gt;&lt;/code&gt; component to get the props we need to pass to the platform-agnostic &lt;code&gt;&amp;lt;Button&amp;gt;&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;RemixPressableChildren&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;remix-react-native-pressable&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;Button&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;ui/lib/Button&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="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;Index&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="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&amp;gt;&lt;/span&gt;
          &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;RemixPressableChildren&lt;/span&gt; &lt;span class="na"&gt;to&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"/blog"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;pressableProps&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="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Button&lt;/span&gt; &lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="p"&gt;...&lt;/span&gt;&lt;span class="nx"&gt;pressableProps&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;More publications&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;Button&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;
          &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;RemixPressableChildren&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&amp;gt;&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;p&gt;Now that you've seen how &lt;code&gt;&amp;lt;RemixPressable&amp;gt;&lt;/code&gt; works, here are both the repository and its npm page:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/HorusGoul/remix-react-native-pressable"&gt;github.com/HorusGoul/remix-react-native-pressable&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.npmjs.com/package/remix-react-native-pressable"&gt;npmjs.com/package/remix-react-native-pressable&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Also, I recently published an article about &lt;a href="https://horus.dev/blog/react-native-web-remix-setup"&gt;How to Setup React Native Web in a Remix project&lt;/a&gt;. If you're interested in using React Native with Remix, that's probably the best resource to get started!&lt;/p&gt;




&lt;p&gt;I hope you liked this article! Don't forget to follow me on Twitter if you want to know when I publish something new about web development: &lt;a href="https://twitter.com/HorusGoul"&gt;@HorusGoul&lt;/a&gt;&lt;/p&gt;

</description>
      <category>react</category>
      <category>reactnative</category>
      <category>remix</category>
      <category>webdev</category>
    </item>
    <item>
      <title>How to Setup React Native Web in a Remix project</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Mon, 07 Feb 2022 19:18:58 +0000</pubDate>
      <link>https://dev.to/horusgoul/how-to-setup-react-native-web-in-a-remix-project-357o</link>
      <guid>https://dev.to/horusgoul/how-to-setup-react-native-web-in-a-remix-project-357o</guid>
      <description>&lt;p&gt;I assume you're here because you want to know how to set up React Native Web in your Remix project. Well, you're lucky, I had to do this a few days ago, and I haven't run into trouble with it yet, so here's a tutorial about it:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Let's get started!&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;The result of this tutorial is also available as a GitHub repository that you can just clone to get started with your project: &lt;a href="https://github.com/HorusGoul/remix-react-native-web-starter"&gt;https://github.com/HorusGoul/remix-react-native-web-starter&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Installing the react-native-web package
&lt;/h2&gt;

&lt;p&gt;The first thing you have to do is install the &lt;code&gt;react-native-web&lt;/code&gt; package. However, since we can't customize our build process because Remix doesn't allow it yet, we'll need to use a package manager that will enable you to install a package with an alias. In this case, I decided to use &lt;code&gt;pnpm&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;pnpm add react-native@npm:react-native-web
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then, the types if you're using TypeScript. Note that not all types will be correct for a React Native Web project, but that's out of the scope of this tutorial.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;pnpm add &lt;span class="nt"&gt;--save-dev&lt;/span&gt; @types/react-native
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  2. React Native Web Styles
&lt;/h2&gt;

&lt;p&gt;React Native Web has its own way of handling styles, and for SSR and hydration, they give you a stylesheet element that you have to place in the &lt;code&gt;&amp;lt;head&amp;gt;&lt;/code&gt; of your page.&lt;/p&gt;

&lt;p&gt;We'll pass that stylesheet element to our Root using the Context API. Let's do that by creating a &lt;code&gt;rn-styles.tsx&lt;/code&gt; file inside the &lt;code&gt;app&lt;/code&gt; folder. Here's the content for that file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;createContext&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;useContext&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;ReactNativeStylesContext&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt;
  &lt;span class="nx"&gt;createContext&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;React&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;ReactElement&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;unknown&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;useReactNativeStyles&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;useContext&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ReactNativeStylesContext&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;??&lt;/span&gt; &lt;span class="nx"&gt;ReplaceWithStylesSSRTag&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;ReplaceWithStylesSSRTag&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;meta&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"REPLACE_WITH_STYLES"&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now, let's move to the &lt;code&gt;app/root.tsx&lt;/code&gt; file. We'll now use the &lt;code&gt;useReactNativeStyles()&lt;/code&gt; hook and put the &lt;code&gt;stylesElement&lt;/code&gt; inside the &lt;code&gt;&amp;lt;head&amp;gt;&lt;/code&gt;. Also, we'll wrap the &lt;code&gt;&amp;lt;Outlet /&amp;gt;&lt;/code&gt; component with a View with a few properties to match the React Native Web behavior.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="p"&gt;...&lt;/span&gt;

&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;useReactNativeStyles&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;./rn-styles&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;View&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;StyleSheet&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react-native&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="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;App&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;stylesElement&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;useReactNativeStyles&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;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;html&lt;/span&gt; &lt;span class="na"&gt;lang&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"en"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;head&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        ...

        &lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;stylesElement&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;head&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;body&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        ...

        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;View&lt;/span&gt; &lt;span class="na"&gt;pointerEvents&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"box-none"&lt;/span&gt; &lt;span class="na"&gt;style&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;styles&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;appContainer&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Outlet&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;View&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;

        ...
      &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;body&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;html&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&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;styles&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;StyleSheet&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;create&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="na"&gt;appContainer&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;flex&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&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;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We also need to add a global stylesheet to Remix that contains the following.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nt"&gt;html&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;display&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;flex&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;p&gt;&lt;em&gt;Take a look at the &lt;a href="https://remix.run/docs/en/v1/guides/styling#regular-stylesheets"&gt;Remix Docs about Stylesheets&lt;/a&gt; if you don't know how to add CSS in a Remix project.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  3. SSR and Hydration
&lt;/h2&gt;

&lt;p&gt;Assuming you haven't modified the &lt;code&gt;app/entry.client.tsx&lt;/code&gt; file, just replace its contents with the following:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;RemixBrowser&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;remix&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;hydrate&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react-dom&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;AppRegistry&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react-native&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;ReactNativeStylesContext&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;./rn-styles&lt;/span&gt;&lt;span class="dl"&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;App&lt;/span&gt; &lt;span class="o"&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="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;RemixBrowser&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;;&lt;/span&gt;

&lt;span class="nx"&gt;AppRegistry&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;registerComponent&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;App&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="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;App&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="c1"&gt;// @ts-ignore&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;getStyleElement&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;AppRegistry&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;getApplication&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;App&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="nx"&gt;hydrate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;ReactNativeStylesContext&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Provider&lt;/span&gt; &lt;span class="na"&gt;value&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;getStyleElement&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;App&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;ReactNativeStylesContext&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Provider&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;,&lt;/span&gt;
  &lt;span class="nb"&gt;document&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;What's going on with that code? We're using React Native Web &lt;code&gt;AppRegistry&lt;/code&gt; to get the initial styles for the app and avoid hydration from failing.&lt;/p&gt;

&lt;p&gt;Now, let's move to the &lt;code&gt;app/entry.server.tsx&lt;/code&gt; file, where we'll do a similar thing. Take a look at the code:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;renderToString&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;renderToStaticMarkup&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react-dom/server&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;RemixServer&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;remix&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="kd"&gt;type&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;EntryContext&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;remix&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;AppRegistry&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react-native&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;ReplaceWithStylesSSRTag&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;./rn-styles&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&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="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;handleRequest&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="nx"&gt;request&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;Request&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nx"&gt;responseStatusCode&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;number&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nx"&gt;responseHeaders&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;Headers&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nx"&gt;remixContext&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;EntryContext&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;App&lt;/span&gt; &lt;span class="o"&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="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;RemixServer&lt;/span&gt; &lt;span class="na"&gt;context&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;remixContext&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt; &lt;span class="na"&gt;url&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;request&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;url&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;;&lt;/span&gt;

  &lt;span class="nx"&gt;AppRegistry&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;registerComponent&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;App&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="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;App&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;markup&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;renderToString&lt;/span&gt;&lt;span class="p"&gt;(&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;App&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;);&lt;/span&gt;

  &lt;span class="c1"&gt;// @ts-ignore&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;getStyleElement&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;AppRegistry&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;getApplication&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;App&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="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;stylesMarkup&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;renderToStaticMarkup&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;getStyleElement&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;

  &lt;span class="nx"&gt;markup&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;markup&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;replace&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="nx"&gt;renderToStaticMarkup&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ReplaceWithStylesSSRTag&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
    &lt;span class="nx"&gt;stylesMarkup&lt;/span&gt;
  &lt;span class="p"&gt;);&lt;/span&gt;

  &lt;span class="nx"&gt;responseHeaders&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="kd"&gt;set&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Content-Type&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;text/html&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nx"&gt;Response&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;&amp;lt;!DOCTYPE html&amp;gt;&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nx"&gt;markup&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;status&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;responseStatusCode&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;headers&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;responseHeaders&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;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This time, we're not passing the app styles using the ReactNativeStylesContext, but injecting them inside the markup by replacing a custom meta tag.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Using React Native Web components
&lt;/h2&gt;

&lt;p&gt;One last thing you could do if you're doing this in a new project is to go ahead and replace your &lt;code&gt;app/routes/index.tsx&lt;/code&gt; with the following:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;Text&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;View&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react-native&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&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="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;Index&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;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;View&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Text&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;Hello, world!&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;Text&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;View&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&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;p&gt;Then do &lt;code&gt;pnpm dev&lt;/code&gt; and open your project in the browser to see your first Remix route rendered with React Native Web components!&lt;/p&gt;




&lt;p&gt;I hope you liked this article! Don't forget to follow me on Twitter if you want to know when I publish something new about web development: &lt;a href="https://twitter.com/HorusGoul"&gt;@HorusGoul&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>7 Resources to Improve Your HTML and Accessibility Skills</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Tue, 01 Feb 2022 09:48:29 +0000</pubDate>
      <link>https://dev.to/horusgoul/7-resources-to-improve-your-html-and-accessibility-skills-7ak</link>
      <guid>https://dev.to/horusgoul/7-resources-to-improve-your-html-and-accessibility-skills-7ak</guid>
      <description>&lt;p&gt;Some devs say HTML is easy, but it's not. HTML is complex, and the lack of time put into it makes the web harder to use for many people.&lt;/p&gt;

&lt;p&gt;Do your users a favor and learn HTML.&lt;/p&gt;

&lt;p&gt;Here is a list with 7 resources about HTML and Accessibility 👇&lt;/p&gt;

&lt;h2&gt;
  
  
  1. HTMHell
&lt;/h2&gt;

&lt;p&gt;The &lt;a href="https://htmhell.dev"&gt;htmhell.dev&lt;/a&gt; website has a "Hell" category with many bad practices with details and tips on how to fix them. These are all taken from real websites. &lt;/p&gt;

&lt;p&gt;It also has a "Heaven" section with tips.&lt;/p&gt;

&lt;p&gt;Follow them on Twitter! &lt;a href="https://twitter.com/htm_hell"&gt;@htm_hell&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  2. &lt;a href="https://inclusive-components.design"&gt;inclusive-components.design&lt;/a&gt;
&lt;/h2&gt;

&lt;p&gt;Quoting their website: "A blog trying to be a pattern library, with a focus on inclusive design. Each post explores a common interface component and comes up with a better, more robust, and accessible version of it."&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Learn Forms! by &lt;a href="https://twitter.com/ChromiumDev"&gt;@ChromiumDev&lt;/a&gt;
&lt;/h2&gt;

&lt;p&gt;This is an entire course dedicated to HTML form fields. It covers the basics, testing, design, accessibility, localization, security, and more advanced stuff.&lt;/p&gt;

&lt;p&gt;It also has mini quizzes at the end of each section!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://web.dev/learn/forms/"&gt;https://web.dev/learn/forms/&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Accessible Tables Tutorial
&lt;/h2&gt;

&lt;p&gt;The &lt;a href="https://twitter.com/w3cdev"&gt;@w3cdev&lt;/a&gt; has multiple tutorials about Web Accessibility, I went through this one the other day, and I learned a lot 🤯 &lt;/p&gt;

&lt;p&gt;Check it out: &lt;a href="https://www.w3.org/WAI/tutorials/tables/"&gt;https://www.w3.org/WAI/tutorials/tables/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;They also have Page Structure, Menus, Images, Forms, and Carousels tutorials.&lt;/p&gt;

&lt;h2&gt;
  
  
  5. The Best Accessibility Practices To Use Emojis on the Web
&lt;/h2&gt;

&lt;p&gt;This article talks about how to use emojis on your websites and apps. The best part is that you can also apply the same practices for SVG and Font Icons.&lt;/p&gt;

&lt;p&gt;P.S. I wrote this one 😛 &lt;/p&gt;

&lt;p&gt;&lt;a href="https://horus.dev/blog/happy-emoji-day-the-best-accessibility-practices-to-use-emojis-on-the-web"&gt;https://horus.dev/blog/happy-emoji-day-the-best-accessibility-practices-to-use-emojis-on-the-web&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  6. Responsive Images
&lt;/h2&gt;

&lt;p&gt;This article by &lt;a href="https://twitter.com/mozdevnet"&gt;@MozDevNet&lt;/a&gt; teaches about the concept of responsive images. If you go through it, you'll learn to use features like &lt;code&gt;srcset&lt;/code&gt; and the &lt;code&gt;&amp;lt;picture&amp;gt;&lt;/code&gt; element to implement responsive images on your websites and apps.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Learn/HTML/Multimedia_and_embedding/Responsive_images"&gt;https://developer.mozilla.org/en-US/docs/Learn/HTML/Multimedia_and_embedding/Responsive_images&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  7. axe by &lt;a href="https://twitter.com/dequesystems"&gt;@dequesystems&lt;/a&gt;
&lt;/h2&gt;

&lt;p&gt;axe is tool to run accessibility checks against your website and components. &lt;/p&gt;

&lt;p&gt;You can use it as a browser extension or include &lt;code&gt;jest-axe&lt;/code&gt; or &lt;code&gt;axe-core&lt;/code&gt; in your automated testing pipeline.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.deque.com/axe/"&gt;https://www.deque.com/axe/&lt;/a&gt;&lt;/p&gt;




&lt;p&gt;And that's it! HTML is a vital part of the web, and if you don't do it correctly, your websites may be a nightmare to use for some users.&lt;/p&gt;

&lt;p&gt;If you learn HTML, you'll make better websites, and your users will be happier 🎉&lt;/p&gt;




&lt;p&gt;This post was initially published as a Twitter thread, so make sure to follow me on Twitter if you don't want to miss any of the resources I share daily.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;👨‍💻 My Twitter account: &lt;a href="https://twitter.com/HorusGoul"&gt;@HorusGoul&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;🧵 Thread: &lt;a href="https://twitter.com/HorusGoul/status/1484556412655005698"&gt;https://twitter.com/HorusGoul/status/1484556412655005698&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>a11y</category>
      <category>html</category>
      <category>codenewbie</category>
      <category>webdev</category>
    </item>
    <item>
      <title>React Hyper Scroller v3 released!</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Wed, 24 Nov 2021 20:00:40 +0000</pubDate>
      <link>https://dev.to/horusgoul/react-hyper-scroller-v3-released-4577</link>
      <guid>https://dev.to/horusgoul/react-hyper-scroller-v3-released-4577</guid>
      <description>&lt;p&gt;Virtual lists play an essential role in today's web because sometimes, we need to render lists with many items (think about hundreds or even thousands!) or lists with components that are expensive in terms of performance.&lt;/p&gt;

&lt;p&gt;If we need to display a list that contains 5000 items, that means that we'll need to create at least 5000 elements in the DOM. That's expensive and will probably take a bit of time. But that's the best-case scenario; lists are usually composed of items with many elements. If we add up everything, we'll need to render thousands and thousands of elements. That's REALLY EXPENSIVE!&lt;/p&gt;

&lt;p&gt;Virtual lists solve that, allowing you to render only the items that fit on the user's screen. Each time the user scrolls, the lists automatically render new items and remove the ones you left behind. This is awesome, as we won't be wasting resources for elements that won't be on screen unless the user wants to see them!&lt;/p&gt;


&lt;center&gt;
&lt;br&gt;
  &lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--UebpNBEM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://horus-dev-media.s3.amazonaws.com/6f98b6c2-861d-434b-aafb-d2bc6c190317" alt="React Hyper Scroller's logo" width="422" height="390"&gt;&lt;br&gt;
&lt;/center&gt;

&lt;p&gt;&lt;strong&gt;I'm releasing &lt;a href="https://react-hyper-scroller.horus.dev/?utm_source=horus.dev&amp;amp;utm_medium=Social&amp;amp;utm_campaign=release"&gt;React Hyper Scroller v3&lt;/a&gt; today&lt;/strong&gt;, a library that allows you to use virtual lists in your React apps and websites. You'll see that it is not a &lt;code&gt;v1&lt;/code&gt;, but a &lt;code&gt;v3&lt;/code&gt;, that's because I originally created this library to solve the problems of one of my projects, &lt;a href="https://kiddle.xyz"&gt;Kiddle&lt;/a&gt;. These issues are scroll restoration and the ability to render lists of items with unknown sizes.&lt;/p&gt;

&lt;p&gt;React Hyper Scroller's main features are solving these issues, but another one is great DX (Developer Experience). Here's an example from the &lt;a href="https://react-hyper-scroller.horus.dev/docs/intro/?utm_source=horus.dev&amp;amp;utm_medium=Social&amp;amp;utm_campaign=release"&gt;documentation&lt;/a&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight jsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;HyperScroller&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react-hyper-scroller&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="c1"&gt;// List of random numbers from 50 to 300 (inclusive).&lt;/span&gt;
&lt;span class="c1"&gt;// These number represent the height of each item in the list.&lt;/span&gt;
&lt;span class="c1"&gt;// We do this to simulate a list of items with unknown height.&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;items&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nb"&gt;Array&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
  &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;fill&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
  &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;map&lt;/span&gt;&lt;span class="p"&gt;(()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;floor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;random&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;150&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="mi"&gt;50&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;MyList&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;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;HyperScroller&lt;/span&gt; &lt;span class="na"&gt;estimatedItemHeight&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="mi"&gt;175&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;items&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;map&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;item&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;index&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="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt; &lt;span class="na"&gt;key&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;`item-&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;index&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt; &lt;span class="na"&gt;style&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;item&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          Item &lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;index&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;. Height: &lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;item&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;))&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;HyperScroller&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&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;p&gt;One thing to keep in mind is that React Hyper Scroller may not be the best for all use-cases. If it doesn't work for you, there are very cool alternatives like &lt;a href="https://github.com/bvaughn/react-window"&gt;&lt;code&gt;react-window&lt;/code&gt;&lt;/a&gt;, &lt;a href="https://github.com/bvaughn/react-virtualized"&gt;&lt;code&gt;react-virtualized&lt;/code&gt;&lt;/a&gt; or &lt;a href="https://github.com/tannerlinsley/react-virtual"&gt;&lt;code&gt;react-virtual&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Want to know more about React Hyper Scroller?&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://react-hyper-scroller.horus.dev/?utm_source=horus.dev&amp;amp;utm_medium=Social&amp;amp;utm_campaign=release"&gt;Documentation Website&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a href="https://react-hyper-scroller.horus.dev/docs/intro?utm_source=horus.dev&amp;amp;utm_medium=Social&amp;amp;utm_campaign=release"&gt;Getting Started&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/HorusGoul/react-hyper-scroller"&gt;GitHub Repository&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>react</category>
      <category>javascript</category>
      <category>showdev</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Installing Linux on Windows (WSL) is easier than ever</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Fri, 12 Nov 2021 10:07:40 +0000</pubDate>
      <link>https://dev.to/horusgoul/installing-linux-on-windows-wsl-is-easier-than-ever-b16</link>
      <guid>https://dev.to/horusgoul/installing-linux-on-windows-wsl-is-easier-than-ever-b16</guid>
      <description>&lt;p&gt;&lt;strong&gt;TL;DR:&lt;/strong&gt; Open a terminal with admin rights and execute the following command: &lt;code&gt;wsl --install&lt;/code&gt;. If you want to choose a distro, continue reading!&lt;/p&gt;

&lt;p&gt;Until very recently, you had to go through multiple steps to enable WSL in your system. The worst part was that some of them were in the control panel, others in a terminal, and you also had to use the Microsoft Store to choose the Linux distribution you wanted.&lt;/p&gt;

&lt;p&gt;With the recent changes they've made for the release of both Windows 11 and the latest Windows 10 update, installing WSL has become a straightforward task.&lt;/p&gt;

&lt;p&gt;You only need to run one command if you're happy with using Ubuntu as your Linux distribution:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;wsl &lt;span class="nt"&gt;--install&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If you prefer another distribution, with this other command, you can list all the available distros:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;wsl &lt;span class="nt"&gt;--list&lt;/span&gt; &lt;span class="nt"&gt;--online&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And then, run the installation command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;wsl &lt;span class="nt"&gt;--install&lt;/span&gt; &lt;span class="nt"&gt;-d&lt;/span&gt; &amp;lt;distro name&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That's it! You'll have to restart your computer, and then it will ask you for a username and password. Once you create your user, the process will be completed.&lt;/p&gt;

</description>
      <category>linux</category>
      <category>windows</category>
      <category>tutorial</category>
      <category>beginners</category>
    </item>
    <item>
      <title>This project allows you to do streaming to multiple platforms like Twitch, YouTube, or Periscope at the same time!</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Sat, 10 Oct 2020 19:46:55 +0000</pubDate>
      <link>https://dev.to/horusgoul/this-project-allows-you-to-do-streaming-to-multiple-platforms-like-twitch-youtube-or-periscope-at-the-same-time-3lbm</link>
      <guid>https://dev.to/horusgoul/this-project-allows-you-to-do-streaming-to-multiple-platforms-like-twitch-youtube-or-periscope-at-the-same-time-3lbm</guid>
      <description>&lt;p&gt;Hey DEV! 👋&lt;/p&gt;

&lt;p&gt;I just published a GitHub project that allows you to self-host a streaming server so you can stream to multiple platforms at the same time.&lt;/p&gt;

&lt;p&gt;At the moment, Twitch, YouTube, and Periscope are the only supported platforms. Adding a new one is easy, so I encourage you to create a PR if you need support for other platforms 😄&lt;/p&gt;

&lt;p&gt;Here's the repo: &lt;a href="https://github.com/HorusGoul/rtmp-social-multicast" rel="noopener noreferrer"&gt;https://github.com/HorusGoul/rtmp-social-multicast&lt;/a&gt;&lt;/p&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev.to%2Fassets%2Fgithub-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/HorusGoul" rel="noopener noreferrer"&gt;
        HorusGoul
      &lt;/a&gt; / &lt;a href="https://github.com/HorusGoul/rtmp-social-multicast" rel="noopener noreferrer"&gt;
        rtmp-social-multicast
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      Want to stream to Twitch, YouTube, Facebook, and/or Periscope at the same time? That's what this project allows you to do!
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;RTMP Social Multicast Server&lt;/h1&gt;
&lt;/div&gt;
&lt;p&gt;Want to stream to Twitch, Youtube, or Periscope at the same time? That's what this project allows you!&lt;/p&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Prerequisites&lt;/h2&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Git&lt;/li&gt;
&lt;li&gt;Docker&lt;/li&gt;
&lt;li&gt;Docker Compose&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Getting Started&lt;/h2&gt;
&lt;/div&gt;
&lt;p&gt;This guide will go through configuration and how to use it with OBS.
Make sure to have all the prerequisites installed on your machine.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Clone the repo&lt;/li&gt;
&lt;/ol&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;$ git clone https://github.com/HorusGoul/rtmp-social-multicast&lt;/pre&gt;

&lt;/div&gt;
&lt;ol start="2"&gt;
&lt;li&gt;Open the repo&lt;/li&gt;
&lt;/ol&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;$ &lt;span class="pl-c1"&gt;cd&lt;/span&gt; rtmp-social-multicast&lt;/pre&gt;

&lt;/div&gt;
&lt;ol start="3"&gt;
&lt;li&gt;Create a &lt;code&gt;.env&lt;/code&gt; file based on the &lt;code&gt;.env.template&lt;/code&gt; file.&lt;/li&gt;
&lt;/ol&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;$ cp .env.template .env&lt;/pre&gt;

&lt;/div&gt;
&lt;ol start="4"&gt;
&lt;li&gt;
&lt;p&gt;Open and fill the &lt;code&gt;.env&lt;/code&gt; file and fill it with the configuration for the platforms you want to stream.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/HorusGoul/rtmp-social-multicast#configuring-youtube" rel="noopener noreferrer"&gt;Configuring YouTube&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/HorusGoul/rtmp-social-multicast#configuring-twitch" rel="noopener noreferrer"&gt;Configuring Twitch&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/HorusGoul/rtmp-social-multicast#configuring-periscope" rel="noopener noreferrer"&gt;Configuring Periscope&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/HorusGoul/rtmp-social-multicast#configuring-facebook" rel="noopener noreferrer"&gt;Configuring Facebook&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;⚠️  &lt;strong&gt;Make sure to use a strong &lt;code&gt;RTMP_SECRET&lt;/code&gt; if you plan to expose the server to the internet.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;⚠️  &lt;strong&gt;Avoid changing the &lt;code&gt;RTMP_AUTH_SERVER&lt;/code&gt; variable unless you know what you're doing.&lt;/strong&gt;&lt;/p&gt;
&lt;ol start="5"&gt;
&lt;li&gt;Now let's launch everything with Docker Compose&lt;/li&gt;
&lt;/ol&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;$ docker-compose up&lt;/pre&gt;

&lt;/div&gt;
&lt;ol start="6"&gt;
&lt;li&gt;Time to stream! We'll…&lt;/li&gt;
&lt;/ol&gt;
&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/HorusGoul/rtmp-social-multicast" rel="noopener noreferrer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;





&lt;p&gt;Follow me on &lt;a href="https://twitter.com" rel="noopener noreferrer"&gt;Twitter&lt;/a&gt; if you want to know more about my future projects, posts, or whatever I came up with!&lt;/p&gt;

</description>
      <category>showdev</category>
      <category>bash</category>
      <category>docker</category>
      <category>node</category>
    </item>
    <item>
      <title>How to Create React, Vue or TS/JS Projects from the Address Bar 🤯</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Tue, 04 Aug 2020 18:39:49 +0000</pubDate>
      <link>https://dev.to/horusgoul/how-to-create-react-vue-or-ts-js-projects-from-the-address-bar-5f2b</link>
      <guid>https://dev.to/horusgoul/how-to-create-react-vue-or-ts-js-projects-from-the-address-bar-5f2b</guid>
      <description>&lt;p&gt;Did you know that you could just type &lt;a href="https://react.new"&gt;react.new&lt;/a&gt; in the address bar to create a React project? The same applies for Vue, TypeScript and JS too!&lt;/p&gt;

&lt;p&gt;Try it!&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://vue.new"&gt;vue.new&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://ts.new"&gt;ts.new&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://js.new"&gt;js.new&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://react.new"&gt;react.new&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;All thanks to CodeSandbox, I bet there are more but I couldn't find a list. &lt;/p&gt;

&lt;p&gt;Did you know about this? Do you know if there are more special URLs?&lt;/p&gt;

</description>
      <category>typescript</category>
      <category>react</category>
      <category>vue</category>
      <category>javascript</category>
    </item>
    <item>
      <title>Use React's useState and useReducer without Worrying about Immutability</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Mon, 03 Aug 2020 19:39:33 +0000</pubDate>
      <link>https://dev.to/horusgoul/use-react-s-usestate-and-usereducer-without-worrying-about-immutability-2a9k</link>
      <guid>https://dev.to/horusgoul/use-react-s-usestate-and-usereducer-without-worrying-about-immutability-2a9k</guid>
      <description>&lt;p&gt;Struggling with immutability? Finding a lot of spread operators in your codebase? This guide is for you!&lt;/p&gt;

&lt;p&gt;TL;DR: Check out the &lt;a href="https://github.com/immerjs/use-immer"&gt;https://github.com/immerjs/use-immer&lt;/a&gt; library, it's awesome!&lt;/p&gt;




&lt;p&gt;Let's start with this component which allows us to change the user's bio:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight jsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;React&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;useState&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;UserCardEditor&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="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;state&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;setState&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;useState&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
    &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;14&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;email&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;example@domain.com&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;:&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="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Horus&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="na"&gt;bio&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Lorem ipsum dolor sit amet...&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="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;changeBio&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;newBio&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;New bio&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;state&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;bio&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

    &lt;span class="nx"&gt;setState&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;current&lt;/span&gt; &lt;span class="o"&gt;=&amp;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;current&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="na"&gt;profile&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;current&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="na"&gt;bio&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;newBio&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="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      Name: &lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;state&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;p&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;state&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;bio&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;p&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt; &lt;span class="na"&gt;onClick&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;changeBio&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;Change Bio&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&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="nx"&gt;UserCardEditor&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;&lt;iframe src="https://codesandbox.io/embed/use-immer-example-1-ql9br?module=/src/UserCardEditor.js"&gt;
&lt;/iframe&gt;
&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;A few things to care about:&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;We're saving all the state inside the &lt;code&gt;useState&lt;/code&gt; hook. To update it we need to call &lt;code&gt;setState&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;The only thing we're trying to modify here is the user's bio. Notice how it's nested inside the profile object.&lt;/li&gt;
&lt;li&gt;React expects you to replace the state with a new one, to do that you must create a new object and pass it to the &lt;code&gt;setState&lt;/code&gt; function!&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Knowing that, it's simple to understand the reason behind doing this to update the state, right?&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight jsx"&gt;&lt;code&gt;&lt;span class="p"&gt;...&lt;/span&gt;

&lt;span class="nx"&gt;setState&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;current&lt;/span&gt; &lt;span class="o"&gt;=&amp;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;current&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;profile&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;current&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
     &lt;span class="na"&gt;bio&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;newBio&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;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;I don't blame you if you don't think it's simple, because it's not. All these lines of code can be represented with this if you're using mutation:&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight jsx"&gt;&lt;code&gt;&lt;span class="nx"&gt;setState&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;current&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; 
  &lt;span class="nx"&gt;current&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;bio&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;newBio&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;p&gt;You see? A single line instead of cloning the object using the spread operator multiple times. That's simple!&lt;/p&gt;

&lt;p&gt;And... illegal. React expects you to return something from that function, maybe we can just return the same object?&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight jsx"&gt;&lt;code&gt;&lt;span class="nx"&gt;setState&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;current&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; 
  &lt;span class="nx"&gt;current&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;bio&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;newBio&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;current&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;p&gt;Yay! But... the view didn't update! Why? Well... remember that React expects you to use a &lt;strong&gt;NEW&lt;/strong&gt; object, and that's not a new object, it's still the old one, you simply mutated one of it's properties.&lt;/p&gt;

&lt;p&gt;Then... should we just stick to the long and noisy way that uses the spread operator?&lt;/p&gt;

&lt;p&gt;You could, but... Someone already solved this problem!&lt;/p&gt;
&lt;h2&gt;
  
  
  &lt;code&gt;immer&lt;/code&gt; and &lt;code&gt;use-immer&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Ever heard of &lt;code&gt;immer&lt;/code&gt;? You may have heard of this library if you've been playing with Redux! If you didn't, let's take a look into how we can use Immer with React!&lt;/p&gt;

&lt;p&gt;First, let's install it:&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;npm &lt;span class="nb"&gt;install &lt;/span&gt;immer use-immer
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;Now add this import in one of your files:&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="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;useImmer&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;use-immer&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;We were editing the UserCardEditor component right? Let's replace the &lt;code&gt;useState&lt;/code&gt; with &lt;code&gt;useImmer&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight diff"&gt;&lt;code&gt;&lt;span class="gd"&gt;- const [state, setState] = useState({
&lt;/span&gt;&lt;span class="gi"&gt;+ const [state, setState] = useImmer({
&lt;/span&gt;   id: 14,
   email: "example@domain.com",
   profile: {
     name: "Horus",
     bio: "Lorem ipsum dolor sit amet..."
   }
 });
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;For now, it's the same as before... But Immer actually allows us to mutate the data in order to update it! We can now replace our &lt;code&gt;setState&lt;/code&gt; call with this:&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight jsx"&gt;&lt;code&gt;&lt;span class="nx"&gt;setState&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;draft&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; 
  &lt;span class="nx"&gt;draft&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;bio&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;newBio&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;p&gt;Because we're using Immer, the library will work behind the scenes to create a copy of the object and apply the same modifications that we do to the draft object. With this, we can use mutation to update our React state!&lt;/p&gt;

&lt;p&gt;Here's the final code:&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight jsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;React&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;useState&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;useImmer&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;use-immer&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;UserCardEditor&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="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;state&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;setState&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;useImmer&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
    &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;14&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;email&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;example@domain.com&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;:&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="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Horus&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="na"&gt;bio&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Lorem ipsum dolor sit amet...&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="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;changeBio&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;newBio&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;New bio&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;state&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;bio&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

    &lt;span class="nx"&gt;setState&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;draft&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;draft&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;bio&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;newBio&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="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      Name: &lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;state&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;p&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;state&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;profile&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;bio&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;p&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt; &lt;span class="na"&gt;onClick&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;changeBio&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;Change Bio&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&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="nx"&gt;UserCardEditor&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;&lt;iframe src="https://codesandbox.io/embed/use-immer-example-2-h3xwe?module=/src/UserCardEditor.js"&gt;
&lt;/iframe&gt;
&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;use-immer&lt;/code&gt; library also has a replacement for &lt;code&gt;useReducer&lt;/code&gt;, but we won't be covering it here, I recommend you to go to their repo and check out the examples:&lt;/p&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--566lAguM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev.to/assets/github-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/immerjs"&gt;
        immerjs
      &lt;/a&gt; / &lt;a href="https://github.com/immerjs/use-immer"&gt;
        use-immer
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      Use immer to drive state with a React hooks
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;h1&gt;
use-immer&lt;/h1&gt;
&lt;p&gt;A hook to use &lt;a href="https://github.com/mweststrate/immer"&gt;immer&lt;/a&gt; as a React &lt;a href="https://reactjs.org/docs/hooks-intro.html" rel="nofollow"&gt;hook&lt;/a&gt; to manipulate state.&lt;/p&gt;
&lt;h1&gt;
Installation&lt;/h1&gt;
&lt;p&gt;&lt;code&gt;npm install immer use-immer&lt;/code&gt;&lt;/p&gt;
&lt;h1&gt;
API&lt;/h1&gt;
&lt;h2&gt;
useImmer&lt;/h2&gt;
&lt;p&gt;&lt;code&gt;useImmer(initialState)&lt;/code&gt; is very similar to &lt;a href="https://reactjs.org/docs/hooks-state.html" rel="nofollow"&gt;&lt;code&gt;useState&lt;/code&gt;&lt;/a&gt;
The function returns a tuple, the first value of the tuple is the current state, the second is the updater function
which accepts an &lt;a href="https://immerjs.github.io/immer/produce" rel="nofollow"&gt;immer producer function&lt;/a&gt; or a value as argument.&lt;/p&gt;
&lt;h3&gt;
Managing state with immer producer function&lt;/h3&gt;
&lt;p&gt;When passing a function to the updater, the &lt;code&gt;draft&lt;/code&gt; argument can be mutated freely, until the producer ends and the changes will be made immutable and become the next state.&lt;/p&gt;
&lt;p&gt;Example: &lt;a href="https://codesandbox.io/s/l97yrzw8ol" rel="nofollow"&gt;https://codesandbox.io/s/l97yrzw8ol&lt;/a&gt;&lt;/p&gt;
&lt;div class="highlight highlight-source-js position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;&lt;span class="pl-k"&gt;import&lt;/span&gt; &lt;span class="pl-v"&gt;React&lt;/span&gt; &lt;span class="pl-k"&gt;from&lt;/span&gt; &lt;span class="pl-s"&gt;"react"&lt;/span&gt;&lt;span class="pl-kos"&gt;;&lt;/span&gt;
&lt;span class="pl-k"&gt;import&lt;/span&gt; &lt;span class="pl-kos"&gt;{&lt;/span&gt; &lt;span class="pl-s1"&gt;useImmer&lt;/span&gt; &lt;span class="pl-kos"&gt;}&lt;/span&gt; &lt;span class="pl-k"&gt;from&lt;/span&gt; &lt;span class="pl-s"&gt;"use-immer"&lt;/span&gt;&lt;span class="pl-kos"&gt;;&lt;/span&gt;
&lt;span class="pl-k"&gt;function&lt;/span&gt; &lt;span class="pl-v"&gt;App&lt;/span&gt;&lt;span class="pl-kos"&gt;(&lt;/span&gt;&lt;span class="pl-kos"&gt;)&lt;/span&gt; &lt;span class="pl-kos"&gt;{&lt;/span&gt;
  &lt;span class="pl-k"&gt;const&lt;/span&gt; &lt;span class="pl-kos"&gt;[&lt;/span&gt;&lt;span class="pl-s1"&gt;person&lt;/span&gt;&lt;span class="pl-kos"&gt;,&lt;/span&gt; &lt;span class="pl-s1"&gt;updatePerson&lt;/span&gt;&lt;span class="pl-kos"&gt;]&lt;/span&gt; &lt;span class="pl-c1"&gt;=&lt;/span&gt; &lt;span class="pl-en"&gt;useImmer&lt;/span&gt;&lt;span class="pl-kos"&gt;(&lt;/span&gt;&lt;span class="pl-kos"&gt;{&lt;/span&gt;
    &lt;span class="pl-c1"&gt;name&lt;/span&gt;: &lt;span class="pl-s"&gt;"Michel"&lt;/span&gt;&lt;span class="pl-kos"&gt;,&lt;/span&gt;
    &lt;span class="pl-c1"&gt;age&lt;/span&gt;: &lt;span class="pl-c1"&gt;33&lt;/span&gt;
  &lt;span class="pl-kos"&gt;}&lt;/span&gt;&lt;span class="pl-kos"&gt;)&lt;/span&gt;&lt;span class="pl-kos"&gt;;&lt;/span&gt;

  &lt;span class="pl-k"&gt;function&lt;/span&gt; &lt;span class="pl-en"&gt;updateName&lt;/span&gt;&lt;span class="pl-kos"&gt;(&lt;/span&gt;&lt;span class="pl-s1"&gt;name&lt;/span&gt;&lt;span class="pl-kos"&gt;)&lt;/span&gt; &lt;span class="pl-kos"&gt;{&lt;/span&gt;
    &lt;span class="pl-s1"&gt;updatePerson&lt;/span&gt;&lt;span class="pl-kos"&gt;(&lt;/span&gt;&lt;span class="pl-s1"&gt;draft&lt;/span&gt; &lt;span class="pl-c1"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="pl-kos"&gt;{&lt;/span&gt;
      &lt;span class="pl-s1"&gt;draft&lt;/span&gt;&lt;span class="pl-kos"&gt;.&lt;/span&gt;&lt;span class="pl-c1"&gt;name&lt;/span&gt; &lt;span class="pl-c1"&gt;=&lt;/span&gt; &lt;span class="pl-s1"&gt;name&lt;/span&gt;&lt;/pre&gt;…
&lt;/div&gt;
&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/immerjs/use-immer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;






&lt;p&gt;That's all! Follow me on &lt;a href="https://twitter.com"&gt;Twitter&lt;/a&gt; if you want to know more about my future projects, posts or whatever I came up with!&lt;/p&gt;

</description>
      <category>react</category>
      <category>codenewbie</category>
      <category>tutorial</category>
      <category>javascript</category>
    </item>
    <item>
      <title>Happy Emoji Day! The Best Accessibility Practices To Use Emojis on the Web 🎉</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Fri, 17 Jul 2020 11:54:11 +0000</pubDate>
      <link>https://dev.to/horusgoul/happy-emoji-day-the-best-accesibility-practices-to-use-emojis-on-the-web-4jf5</link>
      <guid>https://dev.to/horusgoul/happy-emoji-day-the-best-accesibility-practices-to-use-emojis-on-the-web-4jf5</guid>
      <description>&lt;p&gt;Today is the World Emoji Day and because of that I'm going to share with you two tips that will make your Emojis accessible to people using screen readers:&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Replacing Text with Emojis
&lt;/h2&gt;

&lt;p&gt;The first one is going to be useful when we are replacing text with emojis. As an example, we could use the red cross emoji instead of the text "Delete" in a button that triggers the deletion of a record in our app, let's see the bad approach and the good one:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The bad approach:&lt;/strong&gt; This button is not accessible, it will confuse the user because of how emojis are read by screen readers.&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="nt"&gt;&amp;lt;button&amp;gt;&lt;/span&gt;❌&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;The good approach:&lt;/strong&gt; This button is now accessible, we have wrapped the Emoji in a &lt;code&gt;&amp;lt;span /&amp;gt;&lt;/code&gt; tag that has the &lt;code&gt;role=img&lt;/code&gt; and &lt;code&gt;aria-label&lt;/code&gt; attributes.&lt;/p&gt;

&lt;p&gt;For a screen reader, the emoji will behave like an image with a description, and it will simply read it's description making this code accessible!&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="nt"&gt;&amp;lt;button&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;span&lt;/span&gt; &lt;span class="na"&gt;role=&lt;/span&gt;&lt;span class="s"&gt;"img"&lt;/span&gt; &lt;span class="na"&gt;aria-label=&lt;/span&gt;&lt;span class="s"&gt;"Delete"&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;
&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  2. Using Emojis as Decoration
&lt;/h2&gt;

&lt;p&gt;This case is useful when we are using emojis as decoration, that's also when we don't want screen readers to see them, and for that we can use the &lt;code&gt;aria-hidden&lt;/code&gt; attribute with the value &lt;code&gt;true&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Here's an example with a bad and a good approach:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The bad approach:&lt;/strong&gt; This button is accessible but doesn't follow the best practices as the screen reader will try to read the emoji and that will create unnecessary noise for the user.&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="nt"&gt;&amp;lt;button&amp;gt;&lt;/span&gt;❌ Delete&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;The good approach:&lt;/strong&gt; This button will work perfectly in screen readers because we're telling it to ignore the emoji. That's it!&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="nt"&gt;&amp;lt;button&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;span&lt;/span&gt; &lt;span class="na"&gt;role=&lt;/span&gt;&lt;span class="s"&gt;"img"&lt;/span&gt; &lt;span class="na"&gt;aria-hidden=&lt;/span&gt;&lt;span class="s"&gt;"true"&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; Delete
&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  It works with icons too! 🤯
&lt;/h2&gt;

&lt;p&gt;It can't be all about emojis today, I'm pretty sure your app has icons, maybe you got those from FontAwesome? Material? An SVG you created?&lt;/p&gt;

&lt;p&gt;Are they accessible? Because the tips we just saw also apply for icons!&lt;/p&gt;

&lt;p&gt;So... even if you don't use emojis, &lt;strong&gt;what are you waiting for? Go and make your apps more accessible!&lt;/strong&gt;&lt;/p&gt;




&lt;p&gt;Follow me on Twitter &lt;a href="https://dev.to@HorusGoul"&gt;https://twitter.com/HorusGoul&lt;/a&gt; if you want to learn more about web development! &lt;/p&gt;

</description>
      <category>a11y</category>
      <category>webdev</category>
      <category>html</category>
      <category>emojiday</category>
    </item>
    <item>
      <title>My New Website Built with Next.js, TailwindCSS and Vercel</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Fri, 12 Jun 2020 16:00:32 +0000</pubDate>
      <link>https://dev.to/horusgoul/my-new-website-built-with-next-js-tailwindcss-and-vercel-1pkb</link>
      <guid>https://dev.to/horusgoul/my-new-website-built-with-next-js-tailwindcss-and-vercel-1pkb</guid>
      <description>&lt;p&gt;One of the things that has been always bugging me is to not have a personal website that makes me feel like I've done a great job after finishing it. That's mainly because I wanted to build a website but didn't know what to put in it.&lt;/p&gt;

&lt;p&gt;That's what changed this time because I knew what to put in my website, and also was really inspired and it took me very little time to discover how I wanted to display the content. In my previous attempts to have an amazing website, I wasn't able to find this kind of inspiration so most of the times I felt frustated and ended up looking for a template that would temporarily do the job.  &lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--pI9cuH_7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/d6htypzubsndk30rte6c.png" alt="" width="880" height="581"&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;em&gt;My previous website, a blog built with a Gatsby template&lt;/em&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;As I usually do when I'm building personal projects, I decided to try some new tools that I haven't used before, in this case, Next.js and TailwindCSS were the new shiny things I wanted to take a look into.&lt;/p&gt;

&lt;p&gt;I've been reading a lot of things regarding Next.js in the last few years, but in the last few months they released a new feature called &lt;a href="https://nextjs.org/docs/advanced-features/static-html-export"&gt;Static HTML Export&lt;/a&gt; that allows developers to use the framework as a static site generator. Also, Next.js is mainly developed by &lt;a href="https://vercel.com"&gt;Vercel&lt;/a&gt;, a platform that allows you to deploy Next.js apps (and other kind of apps) to the cloud, combining CDN for static content and Serverless functions for your API and Server Side Rendered (SSR) routes. The best part of it is that they manage all of that for you, and with &lt;strong&gt;zero config&lt;/strong&gt; you can get your Next.js app easily deployed in their platform.&lt;/p&gt;

&lt;p&gt;Finally, I decided to go with TailwindCSS to style the website, I found that it's really easy to use and that once you learn the basics, applying styles to something in your website it's just a matter of adding a few utility classes to the elements you want to modify.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--ni1fe4hV--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/i6arxgpyzfui8di7060q.png" alt="" width="880" height="503"&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;em&gt;Vercel + Next.js + TailwindCSS = horus.dev&lt;/em&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;If you mix those tools, you'll eventually get a website like the one I have been building for the last few weeks, I bet you're already curious about what my new website looks like so... here's the link!&lt;/p&gt;

&lt;p&gt;➡️ &lt;a href="https://horus.dev"&gt;https://horus.dev&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;But wait, there's more, it's also open source so feel free to take a look to the code on &lt;a href="https://github.com/HorusGoul/horus.dev"&gt;GitHub&lt;/a&gt;! &lt;/p&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--566lAguM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev.to/assets/github-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/HorusGoul"&gt;
        HorusGoul
      &lt;/a&gt; / &lt;a href="https://github.com/HorusGoul/horus.dev"&gt;
        horus.dev
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      My personal website, built with Next.js, React, TailwindCSS and Vercel.
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;h1&gt;
&lt;a href="https://horus.dev" rel="nofollow"&gt;horus.dev&lt;/a&gt;
&lt;/h1&gt;
&lt;p&gt;The code of my current website, built using &lt;a href="https://reactjs.org" rel="nofollow"&gt;React&lt;/a&gt; and &lt;a href="https://nextjs.org/" rel="nofollow"&gt;Next.js&lt;/a&gt;, &lt;a href="https://tailwindcss.com" rel="nofollow"&gt;TailwindCSS&lt;/a&gt;, and finally &lt;a href="https://vercel.com" rel="nofollow"&gt;Vercel&lt;/a&gt; because it's the best platform to deploy Next.js projects.&lt;/p&gt;

&lt;p&gt;Bootstrapped using &lt;a href="https://github.com/HorusGoul/next-ts-starter"&gt;HorusGoul/next-ts-starter&lt;/a&gt;&lt;/p&gt;
&lt;/div&gt;



&lt;/div&gt;
&lt;br&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/HorusGoul/horus.dev"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;br&gt;
&lt;/div&gt;
&lt;br&gt;


&lt;p&gt;What do you think about my new website? Make me know about your ideas on how I could improve it in the comments 😊&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>showdev</category>
      <category>react</category>
      <category>css</category>
    </item>
    <item>
      <title>Using HTML, CSS, and JavaScript to Create OBS Plugins for Your Live Streaming Sessions</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Sat, 11 Apr 2020 14:21:08 +0000</pubDate>
      <link>https://dev.to/horusgoul/using-html-css-and-javascript-to-create-obs-plugins-for-your-live-streaming-sessions-45ij</link>
      <guid>https://dev.to/horusgoul/using-html-css-and-javascript-to-create-obs-plugins-for-your-live-streaming-sessions-45ij</guid>
      <description>&lt;p&gt;A few days ago, I decided to give a try to live coding on Twitch. I developed a bot for one of the forums I visit regularly and it was a great experience, a lot of people visited the streaming and the big majority stayed for a while.&lt;/p&gt;

&lt;p&gt;Because of that, I have been looking for ways to improve the experience of my live coding sessions and then I thought that one of these ways could be creating my own plugins for OBS (Open Broadcaster Software).&lt;/p&gt;

&lt;p&gt;I found out that OBS plugins can be written in C++, but that's overkill! Then I thought that maybe there's another way using web technologies (HTML, CSS, and JS), that's when I discovered the &lt;code&gt;Browser&lt;/code&gt; source.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fnt242vt70j7e4sonz54s.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fnt242vt70j7e4sonz54s.png" alt="Browser Source"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This type of source allows you to use an internal browser that supports modern web capabilities, just point it to an URL or a local HTML file and start building a dynamic experience for your viewers!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F2b2yyj2ag6n58l1z3s7t.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F2b2yyj2ag6n58l1z3s7t.png" alt="Browser Source Properties"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Once I got to know about this, I decided to use &lt;a href="https://preactjs.com/" rel="noopener noreferrer"&gt;Preact&lt;/a&gt; with &lt;a href="https://github.com/developit/htm" rel="noopener noreferrer"&gt;HTM&lt;/a&gt; and plain CSS as the stack to build my plugins. I believe that this stack rocks for this use case because it doesn't require a build step, just go ahead and use the platform!&lt;/p&gt;

&lt;p&gt;Here's a GIF of my first OBS plugin, which loads the latest posts of my dev.to profile in case someone wants to read one of my publications after the stream finishes:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fjy2zusgwrplz81yk3rey.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fjy2zusgwrplz81yk3rey.gif" alt="Plugin that retrieves my latest dev.to publications"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;After building my first plugin and seeing that this stack rocks, I have created a repository that you can use as a template to develop obs plugins with this stack: &lt;a href="https://github.com/HorusGoul/preact-obs-plugin" rel="noopener noreferrer"&gt;HorusGoul/preact-obs-plugin&lt;/a&gt;.&lt;/p&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev.to%2Fassets%2Fgithub-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/HorusGoul" rel="noopener noreferrer"&gt;
        HorusGoul
      &lt;/a&gt; / &lt;a href="https://github.com/HorusGoul/preact-obs-plugin" rel="noopener noreferrer"&gt;
        preact-obs-plugin
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;Preact OBS Plugin&lt;/h1&gt;

&lt;/div&gt;
&lt;p&gt;This is a template that can be used to build OBS plugins (or webapps!)&lt;/p&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;$ git clone https://github.com/HorusGoul/preact-obs-plugin hello-world-obs-plugin&lt;/pre&gt;

&lt;/div&gt;
&lt;p&gt;The dependencies are downloaded from CDNs, just launch a web server with &lt;code&gt;npx serve&lt;/code&gt; and use the local URL in your &lt;code&gt;Browser&lt;/code&gt; source on OBS.&lt;/p&gt;
&lt;p&gt;I recommend you to use &lt;code&gt;npx live-server&lt;/code&gt; to develop, it will reload your website whenever you change one of the files.&lt;/p&gt;
&lt;/div&gt;



&lt;/div&gt;
&lt;br&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/HorusGoul/preact-obs-plugin" rel="noopener noreferrer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;br&gt;
&lt;/div&gt;
&lt;br&gt;





&lt;p&gt;&lt;em&gt;Follow me on &lt;a href="https://twitter.com/HorusGoul" rel="noopener noreferrer"&gt;Twitter&lt;/a&gt; if you want to know about my future articles, projects or whatever I come up with!&lt;/em&gt;&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>javascript</category>
      <category>livecoding</category>
      <category>html</category>
    </item>
    <item>
      <title>How To Improve Your Problem-Solving Skills</title>
      <dc:creator>Horus Lugo</dc:creator>
      <pubDate>Thu, 12 Mar 2020 21:56:52 +0000</pubDate>
      <link>https://dev.to/horusgoul/how-to-improve-your-problem-solving-skills-1gl0</link>
      <guid>https://dev.to/horusgoul/how-to-improve-your-problem-solving-skills-1gl0</guid>
      <description>&lt;p&gt;Alice just finished her first development course, she wanted to continue learning and getting more in-depth knowledge about the universe of possibilities that programming offered her.&lt;/p&gt;

&lt;p&gt;She also wanted a job, and deciding to build a portfolio was her best choice to be able to do some interviews as soon as possible.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;How did she start?&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;At first, she began using what she learned in the course. Then, she continued to mix that content with the answers she found while searching for the problems that started to arise.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--rXXeTmhd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/in5bwmqkmjhcvirvl4xi.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--rXXeTmhd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/in5bwmqkmjhcvirvl4xi.jpeg" alt="Image that symbolizes the beginning of her career, a little kid in front of a bunch of stairs" width="880" height="495"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A lot of challenges were appearing in front of her, and that’s when she realized that there was one important thing that the course didn’t teach her.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Problem-solving&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;&lt;em&gt;Problem-solving is one of the most valued soft skills a programmer should have in their toolbox, and Alice was just training to become a better problem solver without even knowing it.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;She got really good at it while building her portfolio, and that wasn’t the only thing learned, she also got to know new tools, concepts, tricks, etc.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--G5K84zb_--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/singa3et0745uaaxcpmk.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--G5K84zb_--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/singa3et0745uaaxcpmk.jpeg" alt="Image that symbolizes problem-solving, a person holding a rubik cube" width="880" height="587"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Once she finished her portfolio, she applied to a few jobs and ended up working in one of the companies she wanted the most.&lt;/p&gt;

&lt;p&gt;She continued learning, and, over the years, she built an amazing career! Mainly because creating things led her to improve her problem-solving skills along with other hard skills she learned on the go. &lt;/p&gt;

&lt;p&gt;When people ask Alice how it was when she started coding, she always talks about how she got through her first portfolio and how improving your problem-solving skills can boost your career.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--gA4KV9lc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/qwgfzewvcf9wcqfohsb1.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--gA4KV9lc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/qwgfzewvcf9wcqfohsb1.jpeg" alt="Image that symbolizes success, a person jumping with a happy pose" width="880" height="495"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;p&gt;That’s the story of Alice, If you’re starting with programming, I recommend you to follow her advice so...&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Go and build some projects while improving your problem-solving skills at the same time!&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;If you don’t know what to build, here’s a repository with a lot of things that you can start building after you finish reading this post:&lt;/p&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--566lAguM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev.to/assets/github-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/karan"&gt;
        karan
      &lt;/a&gt; / &lt;a href="https://github.com/karan/Projects"&gt;
        Projects
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      📃 A list of practical projects that anyone can solve in any programming language.
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;h1&gt;
Mega Project List&lt;/h1&gt;
&lt;p&gt;A list of practical projects that anyone can solve in any programming language (See &lt;a href="https://github.com/thekarangoel/Projects-Solutions"&gt;solutions&lt;/a&gt;). These projects are divided in multiple categories, and each category has its own folder.&lt;/p&gt;
&lt;p&gt;To get started, simply fork this repo.&lt;/p&gt;
&lt;h2&gt;
&lt;a href="https://github.com/thekarangoel/Projects/blob/master/CONTRIBUTING.md"&gt;CONTRIBUTING&lt;/a&gt;
&lt;/h2&gt;
&lt;p&gt;See ways of &lt;a href="https://github.com/thekarangoel/Projects/blob/master/CONTRIBUTING.md"&gt;contributing&lt;/a&gt; to this repo. You can contribute &lt;strong&gt;solutions&lt;/strong&gt; (will be published in this &lt;a href="https://github.com/thekarangoel/Projects-Solutions"&gt;repo&lt;/a&gt;) to existing problems, &lt;strong&gt;add new projects&lt;/strong&gt; or remove existing ones. Make sure you follow all instructions properly.&lt;/p&gt;
&lt;h2&gt;
&lt;a href="https://github.com/thekarangoel/Projects-Solutions"&gt;Solutions&lt;/a&gt;
&lt;/h2&gt;
&lt;p&gt;You can find implementations of these projects in many other languages by other users in &lt;a href="https://github.com/thekarangoel/Projects-Solutions"&gt;this repo&lt;/a&gt;.&lt;/p&gt;
&lt;h2&gt;
Credits&lt;/h2&gt;
&lt;p&gt;This repo was compiled by &lt;a href="http://twitter.com/karangoel" rel="nofollow"&gt;Karan Goel&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Problems are motivated by the ones shared at:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="http://www.dreamincode.net/forums/topic/78802-martyr2s-mega-project-ideas-list/" rel="nofollow"&gt;Martyr2’s Mega Project List&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://rosettacode.org/" rel="nofollow"&gt;Rosetta Code&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;
Table of Contents&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#numbers"&gt;Numbers&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#classic-algorithms"&gt;Classic Algorithms&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#graph"&gt;Graph&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#data-structures"&gt;Data Structures&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#text"&gt;Text&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#networking"&gt;Networking&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#classes"&gt;Classes&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#threading"&gt;Threading&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#web"&gt;Web&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#files"&gt;Files&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#databases"&gt;Databases&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#graphics-and-multimedia"&gt;Graphics and Multimedia&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/karan/Projects#security"&gt;Security&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;
Numbers&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Find PI to the Nth Digit&lt;/strong&gt; - Enter a number and…&lt;/p&gt;
&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/karan/Projects"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;


&lt;p&gt;Also, there are other soft skills that are indispensable if you want to build a successful career, you may want to learn about them too: &lt;a href="https://hackernoon.com/10-soft-skills-every-developer-needs-66f0cdcfd3f7"&gt;10 Soft Skills Every Developer Needs from Hackernoon&lt;/a&gt;. &lt;/p&gt;




&lt;p&gt;&lt;em&gt;Reach me on &lt;a href="https://twitter.com/HorusGoul"&gt;Twitter&lt;/a&gt; if you build something amazing, I usually share stuff about my future articles, projects or whatever I come up with!&lt;/em&gt;&lt;/p&gt;

</description>
      <category>career</category>
      <category>beginners</category>
      <category>codenewbie</category>
    </item>
  </channel>
</rss>
