<?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>Forem: yuyaohshimo</title>
    <description>The latest articles on Forem by yuyaohshimo (@yuyaohshimo).</description>
    <link>https://forem.com/yuyaohshimo</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%2F137798%2F484cff2a-3107-4813-ac6c-33c38209d624.png</url>
      <title>Forem: yuyaohshimo</title>
      <link>https://forem.com/yuyaohshimo</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/yuyaohshimo"/>
    <language>en</language>
    <item>
      <title>3 Ways Headless Commerce Will Take Your Shopify Store to the Next Level</title>
      <dc:creator>yuyaohshimo</dc:creator>
      <pubDate>Mon, 25 Jan 2021 09:25:58 +0000</pubDate>
      <link>https://forem.com/yuyaohshimo/3-ways-headless-commerce-will-take-your-shopify-store-to-the-next-level-27e9</link>
      <guid>https://forem.com/yuyaohshimo/3-ways-headless-commerce-will-take-your-shopify-store-to-the-next-level-27e9</guid>
      <description>&lt;p&gt;How Ramen Hero, a D2C startup based in the San Francisco Bay area, relaunched their online store including background and history.&lt;/p&gt;

&lt;h2&gt;
  
  
  About This Article
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Those who manage D2C services&lt;/li&gt;
&lt;li&gt;Those who manage online stores&lt;/li&gt;
&lt;li&gt;Shopify users&lt;/li&gt;
&lt;li&gt;Software engineers (especially startup companies)&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Introduction
&lt;/h2&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%2Fkgqdl8buqmu3tep2wqox.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%2Fkgqdl8buqmu3tep2wqox.png" alt="Ramen Hero online store"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I am the senior lead engineer at &lt;a href="https://ramenhero.com" rel="noopener noreferrer"&gt;Ramen Hero&lt;/a&gt; (&lt;a href="https://twitter.com/van_sf_engineer" rel="noopener noreferrer"&gt;@va_sf_engineer&lt;/a&gt;).&lt;/p&gt;

&lt;p&gt;Ramen Hero is a D2C food startup based in the San Francisco Bay area.&lt;/p&gt;

&lt;p&gt;We deliver authentic frozen ramen kits all over America, excluding some areas.&lt;/p&gt;

&lt;p&gt;We rebranded and relaunched our online store in April, 2020.&lt;/p&gt;

&lt;p&gt;At that time, we replaced our system architecture with a modern structure.&lt;/p&gt;




&lt;h2&gt;
  
  
  Pros and Cons of Using Shopify as an Online Store
&lt;/h2&gt;

&lt;p&gt;We are using Shopify as a CMS for creating an online store.&lt;/p&gt;

&lt;p&gt;First of all, for the relaunching, we considered the pros and the cons of our existing online store using Shopify.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;👍 Pros 1: Shopify has all the features necessary for an online store because of CMS&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Shopify has the necessary features for online stores such as the product management feature, the customer management feature, and the order management feature.&lt;/p&gt;

&lt;p&gt;Creating such fetures is costly and requires a lot of human resources.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;👍 Pros 2: Shopify has checkout pages which are available for a variety of payment methods&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;For security reasons, it is not recommended that we create our own checkout pages.&lt;/p&gt;

&lt;p&gt;We are not sure if Shopify’s checkout pages are 100% secure, but those pages should be created by professionals with security experience.&lt;/p&gt;

&lt;p&gt;Also, since they have some payment methods based on the customer’s device like Apple Pay, the customer can complete purchase without entering their shipping address and payment information.&lt;/p&gt;

&lt;p&gt;This feature eliminates the hassle of entering some information and prevents abandonment through the checkout flow.&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%2Fv0iz6531zbycq80drknc.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%2Fv0iz6531zbycq80drknc.png" alt="Shopify checkout page"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;😕 Cons 1: It’s difficult to improve website performance&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The pages rendered by Shopify are published on the server side dynamically each time a customer visits the page.&lt;/p&gt;

&lt;p&gt;Therefore, the rendering page speed is slower than the pages that are rendered statically.&lt;/p&gt;

&lt;p&gt;Also, too many plugins make the rendering page speed slower.&lt;/p&gt;

&lt;p&gt;The redering page speed is very important for online stores.&lt;/p&gt;

&lt;p&gt;Amazon found a 100-ms delay sacrifices their sales by 1%.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;😕 Cons 2: We cannot use general web development stacks&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Typically, the source code of a web application is managed by a version control system such as GitHub.&lt;/p&gt;

&lt;p&gt;Therefore, we can see the difference in changes and we can revert to the previous version if there is a critical bug.&lt;/p&gt;

&lt;p&gt;However, since we can change the code on the Shopify dashboard, we cannot find the difference in changes and it is likely to cause bugs.&lt;/p&gt;

&lt;p&gt;Also, since some codes are added when Shopify plugins are installed automatically, so it is almost impossible to control the source code.&lt;/p&gt;

&lt;p&gt;*Strictly speaking, Shopify publishes a CLI called &lt;a href="https://github.com/Shopify/themekit" rel="noopener noreferrer"&gt;Theme Kit&lt;/a&gt; that also allows us to edit source code locally. Initially, we used this, but since the source code on the dashboard could be changed, version control was almost impossible.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;😕 Cons 3: We cannot always customize the design of the plugin&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;We sometimes need to get features which Shopify doesn’t have to install the plugins.&lt;/p&gt;

&lt;p&gt;It would be nice if plugins had a setting to flexibly change the design, but many plugins have a locked design.&lt;/p&gt;

&lt;p&gt;This will have a significant impact on the branding.&lt;/p&gt;




&lt;h2&gt;
  
  
  Use Shopify as a Part of Headless Commerce
&lt;/h2&gt;

&lt;p&gt;We focesed on having our own front-end while using strong Shopify features for our online store as a back-end so that we could get rid of the cons while leaving the pros we mentioned in the previous section.&lt;/p&gt;

&lt;p&gt;In other words, &lt;strong&gt;use Shopify as a part of headless commerce&lt;/strong&gt; (see more details about headless commerce &lt;a href="https://www.shopify.ca/plus/solutions/headless-commerce" rel="noopener noreferrer"&gt;here&lt;/a&gt;).&lt;/p&gt;

&lt;p&gt;Fortunately, since Shopify provides &lt;strong&gt;Shopify Storefront API&lt;/strong&gt;, we can embrace this architecture.&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%2F4bms7gyidsh0y7o6n26h.jpeg" 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%2F4bms7gyidsh0y7o6n26h.jpeg"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;We created the front-end ourselves and we used the Shopify Storefront API to get online store features like the above image.&lt;/p&gt;

&lt;p&gt;Also, since it is not secure to create checkout pages ourselves, we use Shopify checkout pages.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Front-end&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Since we stopped using Shopify front-end, we could use a framework to maximize website performance.&lt;/p&gt;

&lt;p&gt;So, we decided to use &lt;strong&gt;Next.js&lt;/strong&gt;, which supports SSG (Static Site Generation).&lt;/p&gt;

&lt;p&gt;Next.js is a framework which includes the best practices for modern front-end development.&lt;/p&gt;

&lt;p&gt;Since Next.js can render pages statically due to SSG, the rendering page speed is faster than pages rendered dynamically as I mentioned earlier.&lt;/p&gt;

&lt;p&gt;Also, since Next.js officially supports ISR (Incremental Static Regeneration) at v9.5, we can update pages statically and nearly dynamically.&lt;/p&gt;

&lt;p&gt;Therefore, ISR accomplishes online store content updates without updating the code.&lt;/p&gt;

&lt;p&gt;Another reason we decided to use Next.js is that we wanted to use component-oriented programming.&lt;/p&gt;

&lt;p&gt;Component-oriented programmig makes improvement speed faster because we can change the design to alter only the combination of components.&lt;/p&gt;

&lt;p&gt;Due to this, we can try to change content to continually adjust the needs of customers. That is the most important thing for online stores.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Back-end&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;We added a feature which Shopify doesn’t have to install plugins.&lt;/p&gt;

&lt;p&gt;However, as I mentioned earlier, we may not be able to change the design as we like, or we may not have features we want.&lt;/p&gt;

&lt;p&gt;So, &lt;strong&gt;we developed an API in the back-end which has features to cover our own business logic that Shopify doesn’t cover&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;A structure is simple to use with the Serverless Framework, but we can use the API flexibly because the design is not locked such as plugins.&lt;/p&gt;

&lt;p&gt;For example, since we have a custom zip code validation logic, we created an API endpoint for that.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Final Architecture&lt;/strong&gt;&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%2F1ssx2ktmfll7n8nyjb6x.jpeg" 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%2F1ssx2ktmfll7n8nyjb6x.jpeg"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;We use Next.js for our front-end and that is delivered by &lt;strong&gt;Vercel&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Vercel has a feature to publish changes integrated with GitHub.&lt;/p&gt;

&lt;p&gt;Also, that has some convenient features like automatically creating a preview environment based on a development branch.&lt;/p&gt;

&lt;p&gt;The back-end is a hybrid structure containing a &lt;strong&gt;Shopify StoreFront API and a customized API using the Serverless Framework&lt;/strong&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;👉 Remove restrictions of CMS to use headless commerce&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;It takes a lot of time and money to create a full customized online store. Therefore, we should use CMS.&lt;/p&gt;

&lt;p&gt;However, it is true that we have some restrictions with CMS.&lt;/p&gt;

&lt;p&gt;In terms of online store performance, headless commerce could be an option.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;👉 Create a customized API for features for your business logic&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;We have some restrictions with plugins as well. Also, almost all plugins are not free.&lt;/p&gt;

&lt;p&gt;We can create ideal features to create a customized API.&lt;/p&gt;

&lt;p&gt;Also, since online stores do not have as much traffic, we may be able to have an API for free with serverless architechture like AWS Lambda.&lt;/p&gt;

&lt;p&gt;In addition, we can reuse the features for selling products on other platforms not on the web.&lt;/p&gt;

&lt;p&gt;For example, a chatbot system on SMS or Facebook Messenger.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;👉 Most importantly, think about the efficiency of improvement&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;It is important to try to change the content to continually adjust to the needs of customers.&lt;/p&gt;

&lt;p&gt;To use modern tech stacks like GitHub, Vercel, and Next.js may increase the efficiency of changes.&lt;/p&gt;

&lt;p&gt;As a result, we can optimize the online store for our customers and increase conversion rates.&lt;/p&gt;




&lt;h2&gt;
  
  
  Takeaway
&lt;/h2&gt;

&lt;p&gt;We tried to create a full customized online store at first.&lt;/p&gt;

&lt;p&gt;But, this is not suitable for startups with a small development team.&lt;/p&gt;

&lt;p&gt;The reason is startups require optimal speed above all else, and we were short on time, money, and human resources.&lt;/p&gt;

&lt;p&gt;I know that engineers want to create everything themselves.&lt;/p&gt;

&lt;p&gt;However, &lt;strong&gt;I believe that creating the best system based on the company and team situation is a necessary skill for engineers at startups&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Also, since we reduced development resources to use third-party services, we could not only improve changes in speed, but could also focus on improving quality of service.&lt;/p&gt;

&lt;p&gt;This improvement is essetial for any business.&lt;/p&gt;

&lt;p&gt;We’re hiring engineers who are interested in headless commerce development at Ramen Hero.&lt;/p&gt;

&lt;p&gt;Also, I am available for personal consultations on headless commerce and online store development.&lt;/p&gt;

&lt;p&gt;Please DM me at the above contact via &lt;a href="https://twitter.com/van_sf_engineer" rel="noopener noreferrer"&gt;Twitter&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>nextjs</category>
      <category>shopify</category>
      <category>javascript</category>
      <category>react</category>
    </item>
  </channel>
</rss>
