<?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: Wing Tong</title>
    <description>The latest articles on DEV Community by Wing Tong (@wing_tong).</description>
    <link>https://dev.to/wing_tong</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%2F611940%2F5c63161e-7bf2-4290-98d1-2f0f0bde19fb.jpeg</url>
      <title>DEV Community: Wing Tong</title>
      <link>https://dev.to/wing_tong</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/wing_tong"/>
    <language>en</language>
    <item>
      <title>Implementing Paypal checkout with React - Part 1
</title>
      <dc:creator>Wing Tong</dc:creator>
      <pubDate>Sun, 11 Apr 2021 21:33:06 +0000</pubDate>
      <link>https://dev.to/wing_tong/implementing-paypal-checkout-with-react-part-1-1nab</link>
      <guid>https://dev.to/wing_tong/implementing-paypal-checkout-with-react-part-1-1nab</guid>
      <description>&lt;p&gt;When we are building an e-commerce project, Paypal is one of the most common ways to handle payment. It is easy and straightforward to apply it to your react project. Let's take a closer look at it. 💰👀&lt;br&gt;
&lt;br&gt;&lt;/p&gt;
&lt;h3&gt;
  
  
  Step 1) Create your sandbox accounts
&lt;/h3&gt;

&lt;p&gt;To communicate with the Paypal API, we have to create or log in to your Paypal account in the &lt;a href="https://developer.paypal.com/home/"&gt;developer application&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;In the &lt;strong&gt;Account&lt;/strong&gt; on the left menu, they provide two default sandbox accounts for you. One is a Business sandbox account, the other is a Personal sandbox account. We can use these two accounts to login and pay during the development.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--02QVKueA--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/88linhz1we7hrpjac3ac.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--02QVKueA--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/88linhz1we7hrpjac3ac.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;br&gt;
&lt;br&gt;&lt;/p&gt;
&lt;h3&gt;
  
  
  Step 2) Create a new Paypal app
&lt;/h3&gt;

&lt;p&gt;Next, we have to create a new app. Click on the &lt;strong&gt;My apps &amp;amp; credentials&lt;/strong&gt; and &lt;strong&gt;create a new app&lt;/strong&gt;.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--UrFNL8o7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jvc7fm1puesngdzge994.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--UrFNL8o7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jvc7fm1puesngdzge994.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;br&gt;
We will then receive a &lt;em&gt;Client ID&lt;/em&gt; after creating the new app. Replace your &lt;em&gt;Client ID&lt;/em&gt; with the script below and place it inside the index.html of the public file of the react app.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--evhmBFBz--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/wdik6590j9e66b5we8oy.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--evhmBFBz--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/wdik6590j9e66b5we8oy.png" alt="Alt Text"&gt;&lt;/a&gt;&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;script &lt;/span&gt;&lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"https://www.paypal.com/sdk/js?client-id=YOUR_CLIENT_ID&amp;amp;currency=INR"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/script&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;br&gt;&lt;br&gt;
All the settings are done with the Paypal developer site and our react app! Let's go back to our react app and start building the Paypal component in the next part. 😏&lt;/p&gt;

</description>
      <category>react</category>
      <category>paypal</category>
      <category>checkout</category>
    </item>
  </channel>
</rss>
