<?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: Posen992</title>
    <description>The latest articles on DEV Community by Posen992 (@posen992).</description>
    <link>https://dev.to/posen992</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%2F1281700%2F9a9af558-fc3d-4349-9b39-8f9eca474089.png</url>
      <title>DEV Community: Posen992</title>
      <link>https://dev.to/posen992</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/posen992"/>
    <language>en</language>
    <item>
      <title>How to use Vite to start a React Project</title>
      <dc:creator>Posen992</dc:creator>
      <pubDate>Thu, 15 Feb 2024 14:33:44 +0000</pubDate>
      <link>https://dev.to/posen992/how-to-use-vite-to-start-a-react-project-mk2</link>
      <guid>https://dev.to/posen992/how-to-use-vite-to-start-a-react-project-mk2</guid>
      <description>&lt;h2&gt;
  
  
  Here are the steps to use Vite to start a React Project:
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Navigate to the directory where you want to create the project:
&lt;/h3&gt;

&lt;p&gt;Use the cd command in Terminal to navigate to the directory where you want to create the project. For example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;cd path/to/your/directory
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  2. Create a React project:
&lt;/h3&gt;

&lt;p&gt;In the same directory, run the following command to create a new Vite project with the React template:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;npm create vite@latest my-react-app -- --template react
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This will create a folder named my-react-app in the current directory and initialize the project inside it.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Enter the project directory:
&lt;/h3&gt;

&lt;p&gt;Use the cd command to enter the newly created project directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;cd my-react-app
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  4. Install dependencies:
&lt;/h3&gt;

&lt;p&gt;Run the following command in the project directory to install the project dependencies:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;npm install
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If some errors will occur in this problem, please go to &lt;a href="https://dev.to/posen992/errors-occurred-while-using-vite-30i7"&gt;Errors occurred while using Vite&lt;/a&gt; &lt;/p&gt;

&lt;h3&gt;
  
  
  5. Start the development server:
&lt;/h3&gt;

&lt;p&gt;Finally, run the following command to start the Vite development server:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo npm run dev
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The console shows that the application has started on localhost port 5173, i.e. the address &lt;a href="http://localhost:5173/:"&gt;http://localhost:5173/:&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--m8eLxc50--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://upload-images.jianshu.io/upload_images/3707284-cc5cfd895d1cef6f.png%3FimageMogr2/auto-orient/strip%257CimageView2/2/w/1240" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--m8eLxc50--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://upload-images.jianshu.io/upload_images/3707284-cc5cfd895d1cef6f.png%3FimageMogr2/auto-orient/strip%257CimageView2/2/w/1240" alt="run dev s.png" width="800" height="217"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;By following these steps, you have successfully created and started a new React project in the directory of your choice.&lt;/p&gt;

</description>
      <category>react</category>
      <category>vite</category>
      <category>node</category>
    </item>
    <item>
      <title>Errors occurred while using Vite</title>
      <dc:creator>Posen992</dc:creator>
      <pubDate>Thu, 15 Feb 2024 14:27:31 +0000</pubDate>
      <link>https://dev.to/posen992/errors-occurred-while-using-vite-30i7</link>
      <guid>https://dev.to/posen992/errors-occurred-while-using-vite-30i7</guid>
      <description>&lt;h2&gt;
  
  
  Here are some errors occurred while using Vite.
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Error when create a new Vite project with the React template:
&lt;/h3&gt;

&lt;p&gt;When running the command &lt;code&gt;npm install&lt;/code&gt;, sometimes the terminal displays an error like the one shown in the picture:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--li7bXO7S--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://upload-images.jianshu.io/upload_images/3707284-74290db77d2099ef.png%3FimageMogr2/auto-orient/strip%257CimageView2/2/w/1240" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--li7bXO7S--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://upload-images.jianshu.io/upload_images/3707284-74290db77d2099ef.png%3FimageMogr2/auto-orient/strip%257CimageView2/2/w/1240" alt="create new project.png" width="800" height="341"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Even though the log suggests using this command with &lt;code&gt;--force&lt;/code&gt;, the error persists due to a permission issue. The correct way to resolve this error is to use the command with &lt;code&gt;sudo&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--kejGxn7p--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://upload-images.jianshu.io/upload_images/3707284-b5c471281afccbc6.png%3FimageMogr2/auto-orient/strip%257CimageView2/2/w/1240" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--kejGxn7p--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://upload-images.jianshu.io/upload_images/3707284-b5c471281afccbc6.png%3FimageMogr2/auto-orient/strip%257CimageView2/2/w/1240" alt="solve the error.png" width="800" height="283"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Now, the error has been resolved, and the dependency is installed.&lt;/p&gt;

</description>
      <category>vite</category>
      <category>react</category>
      <category>errors</category>
    </item>
    <item>
      <title>How to install Python3 for Mac</title>
      <dc:creator>Posen992</dc:creator>
      <pubDate>Thu, 15 Feb 2024 13:20:53 +0000</pubDate>
      <link>https://dev.to/posen992/how-to-install-python3-for-mac-3037</link>
      <guid>https://dev.to/posen992/how-to-install-python3-for-mac-3037</guid>
      <description>&lt;h1&gt;
  
  
  Installing Python Environment
&lt;/h1&gt;

&lt;h3&gt;
  
  
  1. Optional: Install Python using Homebrew
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;If you use Homebrew, open the Terminal and run the following command:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  brew install python
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  2. Or, Directly Download the Installer
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Visit the &lt;a href="https://www.python.org/"&gt;official Python website&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Click on "Downloads."&lt;/li&gt;
&lt;li&gt;Choose the latest version of Python.&lt;/li&gt;
&lt;li&gt;Download the installer based on your operating system.
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--NyfJ97BC--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://upload-images.jianshu.io/upload_images/3707284-ef6ba0d4c815a747.png%3FimageMogr2/auto-orient/strip%257CimageView2/2/w/1240" alt="Downloads.png" width="800" height="311"&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  3. Run the Installer
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Once the download is complete, open the downloaded installer.&lt;/li&gt;
&lt;li&gt;Follow the on-screen instructions to complete the installation.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  4. Verify the Installation
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Open the Terminal.&lt;/li&gt;
&lt;li&gt;Type the following command to check if Python is installed:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  python3 --version
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;If the version information is displayed, the installation was successful.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Congratulations! You have successfully completed the first step in using Python.&lt;/p&gt;

</description>
      <category>python</category>
      <category>webdev</category>
    </item>
    <item>
      <title>How to install the Node.js</title>
      <dc:creator>Posen992</dc:creator>
      <pubDate>Thu, 15 Feb 2024 13:03:51 +0000</pubDate>
      <link>https://dev.to/posen992/how-to-install-the-nodejs-54hp</link>
      <guid>https://dev.to/posen992/how-to-install-the-nodejs-54hp</guid>
      <description>&lt;h2&gt;
  
  
  Here are the steps to install Node.js on a Mac:
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Visit the Node.js official website:
&lt;/h3&gt;

&lt;p&gt;Open  the [Node.js official website].&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Choose a version:
&lt;/h3&gt;

&lt;p&gt;The website will display the latest stable version and the long-term support (LTS) version such as below picture. Depending on your needs, select a version. In general, choosing the LTS version is a good option.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4mdz72x6ajpqm77zue9s.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4mdz72x6ajpqm77zue9s.jpeg" alt="Download Picture" width="800" height="453"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Run the Node.js installer:
&lt;/h3&gt;

&lt;p&gt;Once the download is complete, run the downloaded installer. &lt;/p&gt;

&lt;h3&gt;
  
  
  4. Verify the installation:
&lt;/h3&gt;

&lt;p&gt;After installation, you can verify if Node.js and npm were installed successfully by typing the following commands in the Terminal:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;node -v
npm -v
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If everything is set up correctly, these commands will display the installed versions of Node.js and npm like below picture.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvh9ct1q0lwho8cz7pm0w.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvh9ct1q0lwho8cz7pm0w.png" alt="Verify Picture" width="458" height="144"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Now, you have successfully installed Node.js. If you need to globally install Node.js modules later on, you can use the npm command.&lt;/p&gt;

&lt;p&gt;I hope this helps! Feel free to ask if you have any further questions.&lt;/p&gt;

</description>
      <category>node</category>
      <category>webdev</category>
      <category>javascript</category>
    </item>
  </channel>
</rss>
