共享經濟市場的店面(https://vqmarketplace.com)。在React上運行(尚未redux)
將存儲庫克隆到您本地的開發環境中。
git clone https://github.com/vq-labs/vq-marketplace-web-app.git // clones the repository from remote
cd vq-marketplace-web-app // goes to the repository folder
npm install // installs the npm packages from ./package.json
查看.env.example文件並首先進行必要的更改,然後將其重命名為.env文件。您不應該提交此文件,因為它可能包含敏感信息,因此我們在.gitignore中有一個忽略規則
ENV=production //if you run it with an env other than production,
//npm start will also watch for file changes and restart.
PORT=4000
API_URL=http://localhost:8080/api //this is the API url that you connect to.
//If you run vq-marketplace-platform API, you can leave it as it is
TENANT_API_URL=http://localhost:8081/api //this is the URL that manages multi-tenancy.
//If you specify TENANT_ID it means you are only running one tenant
//therefore you can leave this as it is
TENANT_ID=test //this is the TENANT_ID, in other terms the name of the marketplace that you want to setup.
//can be anything. only accepts slug-style.
//By default, all the TENANT_ID in all parts of the app (API, WEB-APP) are test.
//If you change it please make sure that all your env files on every repository
// related to this project has the same TENANT_ID
這將在Localhost:3000上啟動該應用程序。該應用將假設VQ-Marketplace-API可在http:// localhost:8080上找到。
npm start
VQ市場使您能夠在自己的市場店面上工作,同時仍在使用官方的VQ Web服務。您始終可以連接到VQ-LABS託管的市場。構建應用程序時,您只需要調整VQ_API_URL即可。
npm start
要嘗試并快速啟動並連接到現有市場,請輸入:
// starts rental marketplace TaskBee (ala TaskRabbit)
npm run start:taskbee
// starts rental marketplace AirHome (ala AirBnB)
npm run start:airhome
// starts offers marketplace Talentwand (ala Fiverr)
npm run start:talentwand
node ./node_modules/gulp/bin/gulp.js build --API_URL=https://taskrabbit.vqmarketplace.com/api && node scripts/start.js
您可以使用Amazon S3託管文件。確保您在全球安裝了S3-Deploy:
npm install s3-deploy --g
可以通過環境變量或〜/.aws/憑據文件提供AWS憑據。更多詳細信息:http://docs.aws.amazon.com/cli/latest/topic/config-vars.html。請確保在AWS憑據中定義默認值,這將有助於防止部署期間缺少憑證錯誤。有利地,您可以使用AWS的嚮導:
aws configure
以下命令將準備,構建和部署應用程序到S3存儲桶:
AWS_BUCKET_NAME=xxx.vqmarketplace.com
AWS_REGION=eu-central-1
VQ_API_URL=yourMarketplaceId.vqmarketplace.com
npm run deploy
我們已經在這些環境中測試了該應用程序,但是已設置了.nvmrc和package.json引擎以供您提示:(如果您使用NVM,可以使用NVM使用,該使用將為.NVMRC文件,如果您想手動安裝Node和NPM,您可以在包裝中檢查發動機。
Nodejs 7.2.1和NPM 3.10.9在MacOS Sierra 10.12.6上,NodeJS 8.3.0和Windows 10上的NPM 5.6,NodeJS 9.0.0和NPM 5.5.5.1在AWS Linux Ubuntu上16.04.24.24.2
反應
Chrome (最新版本)
野生動物園(最新版本)
支持Internet Explorer和Microsoft Edge(最新版本) VQ MarketPlace Web應用程序還旨在運行最新版本的Internet Explorer。但是,當前的發展未在此瀏覽器中進行特殊測試。請在我們的支持頁面上提交問題。
移動支持VQ MarketPlace Web應用程序並未通過對移動屏幕的全部支持而開發,因為移動應用程序由VQ Labs分別提供。當前的開發未在移動屏幕上進行專門測試。
但是,Web應用程序旨在成為一系列移動設備和屏幕尺寸的工作。請在我們的支持頁面上提交問題。
https://vqlabs.freshdesk.com/support/home
我們遵循以下分支模型:http://nvie.com/posts/a-successful-git-branching-model/
麻省理工學院
VQ實驗室