<?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: Blessing</title>
    <description>The latest articles on DEV Community by Blessing (@bpwldn).</description>
    <link>https://dev.to/bpwldn</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%2F1998836%2Fb0ac9206-596d-41af-bdd1-9336813eb8e5.png</url>
      <title>DEV Community: Blessing</title>
      <link>https://dev.to/bpwldn</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/bpwldn"/>
    <language>en</language>
    <item>
      <title>React.js to CPanel</title>
      <dc:creator>Blessing</dc:creator>
      <pubDate>Thu, 29 Aug 2024 15:57:21 +0000</pubDate>
      <link>https://dev.to/bpwldn/reactjs-to-cpanel-4nki</link>
      <guid>https://dev.to/bpwldn/reactjs-to-cpanel-4nki</guid>
      <description>&lt;p&gt;If you're anything like me, you're just blagging this whole coding thing, feeling a bit out of your depth each day.&lt;/p&gt;

&lt;p&gt;So, when someone provides a detailed walkthrough, you thank God for their existence and keep it moving.&lt;/p&gt;

&lt;p&gt;I'm hoping you'll send out a prayer for me regarding this article because it caused me unnecessary stress. I'll break this down into simple steps for people like me:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 1&lt;/strong&gt;: Run "npm run build" in your terminal (ensure you're in the correct directory—use cd file_name).&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 2&lt;/strong&gt;: Open the folder and locate the "dist" folder.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 3&lt;/strong&gt;: Navigate to cPanel and open "File Manager".&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 4&lt;/strong&gt;: Find "public_html" in File Manager.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 5&lt;/strong&gt;: Create all the separate folders present in your dist folder within public_html. For example, I needed to create a folder named "assets".&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;NOTE:&lt;/strong&gt; This step is crucial. Do not simply copy the zip file or drag and drop the whole folder. You must create individual folders.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 6&lt;/strong&gt;: Enter the folders you've created and select "upload". Now, you can drag and drop the contents into the corresponding folder.&lt;/p&gt;

&lt;p&gt;For instance, I dragged all contents from my local "assets" folder into the cPanel "assets" folder.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 7&lt;/strong&gt;: Return to the main "public_html" folder, go to "upload", and drag and drop any other files that were not in a folder. In my case, this included my icon and index.html.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 8&lt;/strong&gt;: Create a new file named ".htaccess".&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 9&lt;/strong&gt;: Go to settings, select "show hidden files", and save.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 10&lt;/strong&gt;: Select ".htaccess", click on edit, and copy and paste the following code:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
&amp;lt;IfModule mod_rewrite.c&amp;gt;

  RewriteEngine On
  RewriteBase /
  RewriteRule ^index\.html$ - [L]
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteCond %{REQUEST_FILENAME} !-l
  RewriteRule . /index.html [L]

&amp;lt;/IfModule&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Save, and you're done!&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
