<?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: Icegotcha Fantasoxy</title>
    <description>The latest articles on DEV Community by Icegotcha Fantasoxy (@icegotcha).</description>
    <link>https://dev.to/icegotcha</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%2F184342%2Fcd34df6c-25eb-4f95-b1c4-c4e3964ae749.png</url>
      <title>DEV Community: Icegotcha Fantasoxy</title>
      <link>https://dev.to/icegotcha</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/icegotcha"/>
    <language>en</language>
    <item>
      <title>My First Serious Hacktoberfest</title>
      <dc:creator>Icegotcha Fantasoxy</dc:creator>
      <pubDate>Thu, 12 Nov 2020 19:26:21 +0000</pubDate>
      <link>https://dev.to/icegotcha/my-challenge-in-2020-hacktoberfest-n1i</link>
      <guid>https://dev.to/icegotcha/my-challenge-in-2020-hacktoberfest-n1i</guid>
      <description>&lt;p&gt;Hello! 👋&lt;/p&gt;

&lt;p&gt;This is my first post in &lt;strong&gt;dev.to&lt;/strong&gt;. It is about my contributions to &lt;strong&gt;Hacktoberfest 2020&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Introduction
&lt;/h3&gt;

&lt;p&gt;My name is Kotchakorn Wongwisutigul. You can call me by the alias name &lt;strong&gt;"Icegotcha"&lt;/strong&gt; or shortly, &lt;strong&gt;"Ice"&lt;/strong&gt;. I'm a backend developer from Thailand. Mostly, I develop REST APIs and services with Node.js and Spring, but sometimes I develop frontend applications too, with React. &lt;/p&gt;

&lt;p&gt;I love to learn new things every day. I read articles from many websites until 2019. I found &lt;strong&gt;dev.to&lt;/strong&gt; has a lot of interesting articles enough to read every day. I decided to join this community since then.&lt;/p&gt;

&lt;p&gt;Reading articles is not enough to learn new things. I often find a chance to write code and work on projects. Contribution in Hacktoberfest is one of the activities that I'll do to improve my programming skills. ✨&lt;/p&gt;

&lt;h3&gt;
  
  
  Background
&lt;/h3&gt;

&lt;p&gt;I have been working as a developer for 2 years, but I'm new to the open-source world because of mostly working on private projects. Actually, I attended Hacktoberfest the last year, but I made only 1 PR due to many inconveniences. This year I want to try making new own projects and &lt;strong&gt;"open-source"&lt;/strong&gt; is the knowledge I need to have. I think I can't miss an opportunity to attend Hacktoberfest again. 🔥&lt;/p&gt;

&lt;h3&gt;
  
  
  Contributions
&lt;/h3&gt;

&lt;p&gt;I sent the first 2 PRs to a project named &lt;a href="https://github.com/ibitcy/eo-locale"&gt;eo-locale&lt;/a&gt; by &lt;a href="https://github.com/ibitcy"&gt;ibitcy&lt;/a&gt;, a Javascript lightweight i18n library.&lt;/p&gt;


&lt;div class="ltag_github-liquid-tag"&gt;
  &lt;h1&gt;
    &lt;a href="https://github.com/ibitcy/eo-locale/pull/34"&gt;
      &lt;img class="github-logo" alt="GitHub logo" src="https://res.cloudinary.com/practicaldev/image/fetch/s--vJ70wriM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://practicaldev-herokuapp-com.freetls.fastly.net/assets/github-logo-ba8488d21cd8ee1fee097b8410db9deaa41d0ca30b004c0c63de0a479114156f.svg"&gt;
      &lt;span class="issue-title"&gt;
        Validate and improve documentation
      &lt;/span&gt;
      &lt;span class="issue-number"&gt;#34&lt;/span&gt;
    &lt;/a&gt;
  &lt;/h1&gt;
  &lt;div class="github-thread"&gt;
    &lt;div class="timeline-comment-header"&gt;
      &lt;a href="https://github.com/icegotcha"&gt;
        &lt;img class="github-liquid-tag-img" src="https://res.cloudinary.com/practicaldev/image/fetch/s--lJOzAetI--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://avatars3.githubusercontent.com/u/32319739%3Fv%3D4" alt="icegotcha avatar"&gt;
      &lt;/a&gt;
      &lt;div class="timeline-comment-header-text"&gt;
        &lt;strong&gt;
          &lt;a href="https://github.com/icegotcha"&gt;icegotcha&lt;/a&gt;
        &lt;/strong&gt; posted on &lt;a href="https://github.com/ibitcy/eo-locale/pull/34"&gt;&lt;time&gt;Oct 11, 2020&lt;/time&gt;&lt;/a&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;div class="ltag-github-body"&gt;
      &lt;p&gt;According to issue #31&lt;/p&gt;
&lt;p&gt;I improved several parts of the document.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Document structure: I noticed all packages of &lt;code&gt;eo-locale&lt;/code&gt; (&lt;code&gt;@eo-locale/react&lt;/code&gt;,&lt;code&gt;@eo-locale/ preact&lt;/code&gt;, and &lt;code&gt;@ eo-locale/react-native&lt;/code&gt;) have the same components. I think it's better to separate document sections by components and APIs instead of packages. It makes documentation flow and read easier.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;&lt;a href="https://user-images.githubusercontent.com/32319739/95686758-3c9cc980-0c2a-11eb-9c4d-a31112ca5564.png" rel="nofollow"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--StkfWkcc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://user-images.githubusercontent.com/32319739/95686758-3c9cc980-0c2a-11eb-9c4d-a31112ca5564.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;ol start="2"&gt;
&lt;li&gt;
&lt;p&gt;Merge package installation guides into a single page.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Make the page "Installation" to be first page when clicking button "Get Started" on the landing page or "Docs" on the navbar.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Add more information and clearer examples of each component and API.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Update model definition:  Locale (Not update in codes yet)&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;PS. I also noticed the &lt;code&gt;@eo-locale/react-native&lt;/code&gt; can not use &lt;code&gt;formatDate&lt;/code&gt; and &lt;code&gt;formatNumber&lt;/code&gt; because it can not find the object &lt;code&gt;Intl&lt;/code&gt;. I will open a new issue later.&lt;/p&gt;

    &lt;/div&gt;
    &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/ibitcy/eo-locale/pull/34"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;



&lt;div class="ltag_github-liquid-tag"&gt;
  &lt;h1&gt;
    &lt;a href="https://github.com/ibitcy/eo-locale/pull/39"&gt;
      &lt;img class="github-logo" alt="GitHub logo" src="https://res.cloudinary.com/practicaldev/image/fetch/s--vJ70wriM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://practicaldev-herokuapp-com.freetls.fastly.net/assets/github-logo-ba8488d21cd8ee1fee097b8410db9deaa41d0ca30b004c0c63de0a479114156f.svg"&gt;
      &lt;span class="issue-title"&gt;
        Add information about setting up a React Native project
      &lt;/span&gt;
      &lt;span class="issue-number"&gt;#39&lt;/span&gt;
    &lt;/a&gt;
  &lt;/h1&gt;
  &lt;div class="github-thread"&gt;
    &lt;div class="timeline-comment-header"&gt;
      &lt;a href="https://github.com/icegotcha"&gt;
        &lt;img class="github-liquid-tag-img" src="https://res.cloudinary.com/practicaldev/image/fetch/s--lJOzAetI--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://avatars3.githubusercontent.com/u/32319739%3Fv%3D4" alt="icegotcha avatar"&gt;
      &lt;/a&gt;
      &lt;div class="timeline-comment-header-text"&gt;
        &lt;strong&gt;
          &lt;a href="https://github.com/icegotcha"&gt;icegotcha&lt;/a&gt;
        &lt;/strong&gt; posted on &lt;a href="https://github.com/ibitcy/eo-locale/pull/39"&gt;&lt;time&gt;Oct 16, 2020&lt;/time&gt;&lt;/a&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;div class="ltag-github-body"&gt;
      &lt;p&gt;According to the issue #35&lt;/p&gt;

    &lt;/div&gt;
    &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/ibitcy/eo-locale/pull/39"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;


&lt;p&gt;Next, I used knowledge about React and React Hook to make and send a PR to &lt;a href="https://github.com/gregrickaby/reddit-image-viewer"&gt;Reddit image viewer&lt;/a&gt; by &lt;a href="https://github.com/gregrickaby"&gt;Greg Rickaby&lt;/a&gt;.&lt;/p&gt;


&lt;div class="ltag_github-liquid-tag"&gt;
  &lt;h1&gt;
    &lt;a href="https://github.com/gregrickaby/reddit-image-viewer/pull/75"&gt;
      &lt;img class="github-logo" alt="GitHub logo" src="https://res.cloudinary.com/practicaldev/image/fetch/s--vJ70wriM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://practicaldev-herokuapp-com.freetls.fastly.net/assets/github-logo-ba8488d21cd8ee1fee097b8410db9deaa41d0ca30b004c0c63de0a479114156f.svg"&gt;
      &lt;span class="issue-title"&gt;
        Better Infinite Scroll
      &lt;/span&gt;
      &lt;span class="issue-number"&gt;#75&lt;/span&gt;
    &lt;/a&gt;
  &lt;/h1&gt;
  &lt;div class="github-thread"&gt;
    &lt;div class="timeline-comment-header"&gt;
      &lt;a href="https://github.com/icegotcha"&gt;
        &lt;img class="github-liquid-tag-img" src="https://res.cloudinary.com/practicaldev/image/fetch/s--lJOzAetI--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://avatars3.githubusercontent.com/u/32319739%3Fv%3D4" alt="icegotcha avatar"&gt;
      &lt;/a&gt;
      &lt;div class="timeline-comment-header-text"&gt;
        &lt;strong&gt;
          &lt;a href="https://github.com/icegotcha"&gt;icegotcha&lt;/a&gt;
        &lt;/strong&gt; posted on &lt;a href="https://github.com/gregrickaby/reddit-image-viewer/pull/75"&gt;&lt;time&gt;Oct 15, 2020&lt;/time&gt;&lt;/a&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;div class="ltag-github-body"&gt;
      &lt;h3&gt;
&lt;span class="octicon octicon-link"&gt;&lt;/span&gt;Description&lt;/h3&gt;
&lt;p&gt;According to #60, I updated the viewer to fully support infinite scroll as follow:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Update function "fetchData" to fetch only 5 posts in one time &amp;amp; support fetching after a post ID (and remove posts which have no image).&lt;/li&gt;
&lt;li&gt;Add a loading spinner that will display at the bottom when user scroll to bottom of the webpage. I used &lt;a href="https://github.com/davidhu2000/react-spinners"&gt;react-spinners&lt;/a&gt; to implement it.&lt;/li&gt;
&lt;li&gt;Add useEffect() to 3 function
&lt;ul&gt;
&lt;li&gt;first useEffect() will work if a user loads the webpage and search with a new term.&lt;/li&gt;
&lt;li&gt;second useEffect() will work after first useEffect() (when content is fully loaded). This will create an observer (called&lt;a href="https://developer.mozilla.org/en-US/docs/Web/API/Intersection_Observer_API" rel="nofollow"&gt; Intersection Observer API&lt;/a&gt;) that handles loading more content.&lt;/li&gt;
&lt;li&gt;third useEffect() will work if the user scrolls to loading more areas (handled by the observer).&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Update preload link in &lt;code&gt;siteHead.js&lt;/code&gt; to fetch only 5 posts.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Besides,  I also made minor changes:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Let the state &lt;code&gt;results&lt;/code&gt; store an array instead. I found it's easier to handle displaying posts.&lt;/li&gt;
&lt;li&gt;Ruduced calling &lt;code&gt;setSearchTerm&lt;/code&gt; to solve performance issues.&lt;/li&gt;
&lt;li&gt;Update &lt;code&gt;shrinkHeader&lt;/code&gt; to check if &lt;code&gt;el&lt;/code&gt; is null before adding a listener and return a removing listener function used in the first useEffect().&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;
&lt;span class="octicon octicon-link"&gt;&lt;/span&gt;Screenshot&lt;/h3&gt;
&lt;p&gt;&lt;a href="https://imgur.com/a/8rTfmKs" rel="nofollow"&gt;https://imgur.com/a/8rTfmKs&lt;/a&gt;&lt;/p&gt;

    &lt;/div&gt;
    &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/gregrickaby/reddit-image-viewer/pull/75"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;


&lt;p&gt;Then In the middle of the month, I sent the last PR to &lt;a href="https://github.com/thinkswell/javascript-mini-projects"&gt;javascript-mini-projects&lt;/a&gt; by &lt;a href="https://github.com/thinkswell"&gt;Thinkswell&lt;/a&gt;. I made a simple application as below:&lt;/p&gt;


&lt;div class="ltag_github-liquid-tag"&gt;
  &lt;h1&gt;
    &lt;a href="https://github.com/thinkswell/javascript-mini-projects/pull/60"&gt;
      &lt;img class="github-logo" alt="GitHub logo" src="https://res.cloudinary.com/practicaldev/image/fetch/s--vJ70wriM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://practicaldev-herokuapp-com.freetls.fastly.net/assets/github-logo-ba8488d21cd8ee1fee097b8410db9deaa41d0ca30b004c0c63de0a479114156f.svg"&gt;
      &lt;span class="issue-title"&gt;
        Random Quote Generator
      &lt;/span&gt;
      &lt;span class="issue-number"&gt;#60&lt;/span&gt;
    &lt;/a&gt;
  &lt;/h1&gt;
  &lt;div class="github-thread"&gt;
    &lt;div class="timeline-comment-header"&gt;
      &lt;a href="https://github.com/icegotcha"&gt;
        &lt;img class="github-liquid-tag-img" src="https://res.cloudinary.com/practicaldev/image/fetch/s--lJOzAetI--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://avatars3.githubusercontent.com/u/32319739%3Fv%3D4" alt="icegotcha avatar"&gt;
      &lt;/a&gt;
      &lt;div class="timeline-comment-header-text"&gt;
        &lt;strong&gt;
          &lt;a href="https://github.com/icegotcha"&gt;icegotcha&lt;/a&gt;
        &lt;/strong&gt; posted on &lt;a href="https://github.com/thinkswell/javascript-mini-projects/pull/60"&gt;&lt;time&gt;Oct 17, 2020&lt;/time&gt;&lt;/a&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;div class="ltag-github-body"&gt;
      &lt;p&gt;According to issue #13
This is random quote generator that builds with Vue and gets quotes from API.&lt;/p&gt;

    &lt;/div&gt;
    &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/thinkswell/javascript-mini-projects/pull/60"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;


&lt;p&gt;After I finished doing a lot of works. I fixed an issue that I said I would do in the Reddit image viewer.&lt;/p&gt;


&lt;div class="ltag_github-liquid-tag"&gt;
  &lt;h1&gt;
    &lt;a href="https://github.com/gregrickaby/reddit-image-viewer/pull/84"&gt;
      &lt;img class="github-logo" alt="GitHub logo" src="https://res.cloudinary.com/practicaldev/image/fetch/s--vJ70wriM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://practicaldev-herokuapp-com.freetls.fastly.net/assets/github-logo-ba8488d21cd8ee1fee097b8410db9deaa41d0ca30b004c0c63de0a479114156f.svg"&gt;
      &lt;span class="issue-title"&gt;
        Feature/show history
      &lt;/span&gt;
      &lt;span class="issue-number"&gt;#84&lt;/span&gt;
    &lt;/a&gt;
  &lt;/h1&gt;
  &lt;div class="github-thread"&gt;
    &lt;div class="timeline-comment-header"&gt;
      &lt;a href="https://github.com/icegotcha"&gt;
        &lt;img class="github-liquid-tag-img" src="https://res.cloudinary.com/practicaldev/image/fetch/s--lJOzAetI--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://avatars3.githubusercontent.com/u/32319739%3Fv%3D4" alt="icegotcha avatar"&gt;
      &lt;/a&gt;
      &lt;div class="timeline-comment-header-text"&gt;
        &lt;strong&gt;
          &lt;a href="https://github.com/icegotcha"&gt;icegotcha&lt;/a&gt;
        &lt;/strong&gt; posted on &lt;a href="https://github.com/gregrickaby/reddit-image-viewer/pull/84"&gt;&lt;time&gt;Oct 25, 2020&lt;/time&gt;&lt;/a&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;div class="ltag-github-body"&gt;
      &lt;p&gt;Closes #2&lt;/p&gt;
&lt;h3&gt;
&lt;span class="octicon octicon-link"&gt;&lt;/span&gt;Description&lt;/h3&gt;
&lt;p&gt;I develop the feature as follow:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Implement a function to store search terms. Use &lt;code&gt;sessionStorage&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Add the history section to the site header.&lt;/li&gt;
&lt;li&gt;Add a responsive modal to show a list of all used search terms to prevent show too many search terms on the site header. (I use &lt;a href="https://www.npmjs.com/package/react-modal" rel="nofollow"&gt;react-modal&lt;/a&gt;)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Besides, I also made a minor change:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Add &lt;code&gt;browser: true&lt;/code&gt; to &lt;code&gt;env&lt;/code&gt; in eslint.js to prevent show errors (for example: "window is not defined")&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;
&lt;span class="octicon octicon-link"&gt;&lt;/span&gt;Screenshot&lt;/h3&gt;
&lt;p&gt;&lt;a href="https://imgur.com/a/205VQT9" rel="nofollow"&gt;https://imgur.com/a/205VQT9&lt;/a&gt;&lt;/p&gt;

    &lt;/div&gt;
    &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/gregrickaby/reddit-image-viewer/pull/84"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;


&lt;p&gt;In conclusion, I sent 4 PRs and 1 extra PR.&lt;/p&gt;

&lt;p&gt;... and I'll get a beautiful T-shirt! 😇&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s---_TbXtP6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/ea7grfs2z49rx78b3lsh.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s---_TbXtP6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/ea7grfs2z49rx78b3lsh.PNG" alt="My Hacktoberfest screen"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Reflections
&lt;/h3&gt;

&lt;p&gt;I'm very glad to be one of the contributors to the open-source world. I'll try to contribute projects again in and out of the event "Hacktoberfest". 💖&lt;/p&gt;

</description>
      <category>hacktoberfest</category>
      <category>hacktoberfest2020</category>
      <category>opensource</category>
    </item>
  </channel>
</rss>
