forked from paypal/paypal-messaging-components
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathglobals.js
More file actions
54 lines (48 loc) · 1.88 KB
/
globals.js
File metadata and controls
54 lines (48 loc) · 1.88 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
const postRobotGlobals = require('post-robot/globals');
const zoidGlobals = require('zoid/globals');
const { version } = require('./package.json');
const PORT = process.env.PORT || 8080;
module.exports = (env = { TARGET: 'sdk' }) => ({
__ZOID__: {
...zoidGlobals.__ZOID__,
__DEFAULT_CONTAINER__: true,
__DEFAULT_PRERENDER__: true,
__FRAMEWORK_SUPPORT__: true
},
__POST_ROBOT__: {
...postRobotGlobals.__POST_ROBOT__,
__IE_POPUP_SUPPORT__: false
},
__MESSAGES__: {
__VERSION__: env.VERSION || version,
__DEMO__: !!env.demo,
__TARGET__: env.TARGET.toUpperCase(),
__DOMAIN__: {
__LOCAL__: `https://localhost.paypal.com:${PORT}`,
__STAGE__: 'https://www.msmaster.qa.paypal.com',
__SANDBOX__: 'https://www.sandbox.paypal.com',
__PRODUCTION__: 'https://www.paypal.com',
// Manual endpoint override example:
// __MODAL__: {
// __LOCAL__: 'https://localhost.paypal.com:8443'
// },
// __LOGGER_A__: {
// __LOCAL__: 'https://www.msmaster.qa.paypal.com'
// },
__RAMP_EXPERIMENT__: {
__LOCAL__: 'https://www.paypalobjects.com',
__STAGE__: 'https://www.paypalobjects.com',
__SANDBOX__: 'https://www.paypalobjects.com',
__PRODUCTION__: 'https://www.paypalobjects.com'
}
},
__URI__: {
__RAMP_EXPERIMENT__: '/upstream/assets/messaging/modal/ramp-experiment-ssr.json',
__MESSAGE_A__: '/credit-presentment/messages',
__MESSAGE_B__: '/credit-presentment/smart/message',
__MODAL__: '/credit-presentment/smart/modal',
__LOGGER_A__: '/ppcredit/messagingLogger',
__LOGGER_B__: '/credit-presentment/log'
}
}
});