-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Set ROOT_URL for the demo marketplaces #12
Conversation
lyyder
commented
Feb 19, 2020
•
edited
Loading
edited
- Read client ID and root URL from request hostname
- Add a demo specific change log
server/apiRouter.js
Outdated
@@ -14,7 +14,8 @@ const sharetribeSdk = require('sharetribe-flex-sdk'); | |||
const Decimal = require('decimal.js'); | |||
|
|||
const CLIENT_ID = process.env.REACT_APP_SHARETRIBE_SDK_CLIENT_ID; | |||
const ROOT_URL = process.env.REACT_APP_CANONICAL_ROOT_URL; | |||
// Demo specific root url | |||
const ROOT_URL = `https:\/\/${CLIENT_ID}.saunatime-demo.sharetribe.com`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kpuputti I think you are the authority here :) - is this hard-coded domain OK, or should it be avoided?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This repo is purely for the demos, and that's where the demos are running at the moment, so should be perfectly ok to hard code that URL.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we want to enable Stripe in demo marketplaces, we will most likely do another Heroku app so then this hard-coded value will not work. But changing it could be included also to that epic and leave the value like this for now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The root URL is now read from the request hostname.
A change log for demo specific changess
|
||
A change log for demo specific changes. The CHANGELOG.md file is updated from | ||
the upstream repo. This file contains changes that are made solely to the demo | ||
FTW. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we could mention that there are some changes that were made before the changelog was added (e.g. book a call CTA and maybe some restrictions to Stripe forms) or then add those changes to the changelog too if it's easy to find them from commit history.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great point @OtterleyW. I'll resolve the history from past PRs and add it in a different PR to get this one forward.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One comment about changelog but otherwise looks good!