docs: create docs workspace (#5174)
* docs: migrate ui docs to docs universe * created yarn workspace * added eslint and tsconfig configurations * fix eslint configurations * fixed eslint configurations * shared tailwind configurations * added shared ui package * added more shared components * migrating more components * made details components shared * move InlineCode component * moved InputText * moved Loading component * Moved Modal component * moved Select components * Moved Tooltip component * moved Search components * moved ColorMode provider * Moved Notification components and providers * used icons package * use UI colors in api-reference * moved Navbar component * used Navbar and Search in UI docs * added Feedback to UI docs * general enhancements * fix color mode * added copy colors file from ui-preset * added features and enhancements to UI docs * move Sidebar component and provider * general fixes and preparations for deployment * update docusaurus version * adjusted versions * fix output directory * remove rootDirectory property * fix yarn.lock * moved code component * added vale for all docs MD and MDX * fix tests * fix vale error * fix deployment errors * change ignore commands * add output directory * fix docs test * general fixes * content fixes * fix announcement script * added changeset * fix vale checks * added nofilter option * fix vale error
This commit is contained in:
7
www/apps/docs/content/plugins/source/index.mdx
Normal file
7
www/apps/docs/content/plugins/source/index.mdx
Normal file
@@ -0,0 +1,7 @@
|
||||
import DocCardList from '@theme/DocCardList';
|
||||
|
||||
# Source Plugins
|
||||
|
||||
Source plugins are plugins that allow you to migrate from other ecommerce platforms to Medusa.
|
||||
|
||||
<DocCardList />
|
||||
89
www/apps/docs/content/plugins/source/shopify.md
Normal file
89
www/apps/docs/content/plugins/source/shopify.md
Normal file
@@ -0,0 +1,89 @@
|
||||
---
|
||||
addHowToData: true
|
||||
---
|
||||
|
||||
# Shopify Source Plugin
|
||||
|
||||
This document will guide you through installing the shopify source plugin on your Medusa backend.
|
||||
|
||||
## Overview
|
||||
|
||||
If you're migrating from Shopify to Medusa, this plugin will facilitate the process for you. It migrates data related to your products on Shopify to Medusa. It also registers a scheduled job that runs periodically and ensures your data is synced between Shopify and Medusa.
|
||||
|
||||
---
|
||||
|
||||
## Prerequisites
|
||||
|
||||
### Medusa Backend
|
||||
|
||||
A Medusa backend is required to be set up before following along with this document. You can follow the [quickstart guide](../../create-medusa-app.mdx) to get started in minutes.
|
||||
|
||||
### Shopify Account
|
||||
|
||||
Using this plugin requires having a Shopify account with access to development keys and resources.
|
||||
|
||||
### Private Shopify App
|
||||
|
||||
This plugin authenticates with Shopify through a private app that has Read access to products.
|
||||
|
||||
To create a private app:
|
||||
|
||||
1. Open your Shopify store's dashboard
|
||||
2. Choose Apps from the sidebar
|
||||
3. Scroll down and click on "Manage private apps"
|
||||
4. If asked, enable private app development.
|
||||
5. Once enabled, click on the "Create private app" button.
|
||||
6. In the form, enter the app's name and email.
|
||||
7. In the Admin API section, click on "Show inactive Admin API permissions" then, for Products, choose "Read Access".
|
||||
8. Once done, click on the "Save" button.
|
||||
9. Click the "Create App" button in the pop-up that shows up.
|
||||
10. Copy the Password to use for the plugin's configurations.
|
||||
|
||||
---
|
||||
|
||||
## Install Plugin
|
||||
|
||||
In the directory of your Medusa backend, run the following command to install the plugin:
|
||||
|
||||
```bash npm2yarn
|
||||
npm install medusa-source-shopify
|
||||
```
|
||||
|
||||
Then, add the following environment variables to `.env`:
|
||||
|
||||
```bash
|
||||
SHOPIFY_DOMAIN=<YOUR_SHOPIFY_DOMAIN>
|
||||
SHOPIFY_PASSWORD=<YOUR_SHOPIFY_PASSWORD>
|
||||
```
|
||||
|
||||
Where:
|
||||
|
||||
- `<YOUR_SHOPIFY_DOMAIN>` is the subdomain of the Shopify store that you're migrating. If you're not sure what it is, your store's domain should be of the format `<DOMAIN>.myshopify.com`. The `<DOMAIN>` is the value of this environment variable.
|
||||
- `<YOUR_SHOPIFY_PASSWORD>` is the password for the [private app](#private-shopify-app) you created.
|
||||
|
||||
Finally, add the plugin to the `plugins` array in `medusa-config.js`:
|
||||
|
||||
```js title=medusa-config.js
|
||||
const plugins = [
|
||||
// ...,
|
||||
{
|
||||
resolve: "medusa-source-shopify",
|
||||
options: {
|
||||
domain: process.env.SHOPIFY_DOMAIN,
|
||||
password: process.env.SHOPIFY_PASSWORD,
|
||||
},
|
||||
},
|
||||
]
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Test the Plugin
|
||||
|
||||
To test the plugin, run the following command in the directory of the Medusa backend to start the backend:
|
||||
|
||||
```bash
|
||||
npx medusa develop
|
||||
```
|
||||
|
||||
As the backend starts, so does the migration script. The products and its data will be migrated into Medusa.
|
||||
Reference in New Issue
Block a user