-
Notifications
You must be signed in to change notification settings - Fork 212
Expand file tree
/
Copy pathconstants.js
More file actions
37 lines (32 loc) · 1.77 KB
/
constants.js
File metadata and controls
37 lines (32 loc) · 1.77 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
/*
* Copyright (c) 2021, salesforce.com, inc.
* All rights reserved.
* SPDX-License-Identifier: BSD-3-Clause
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause
*/
export const APPLICATION_OCTET_STREAM = 'application/octet-stream'
export const BUILD = 'build'
export const STATIC_ASSETS = 'static_assets'
/** * @deprecated Use ssr-namespace-paths proxyBasePath instead */
export const PROXY_PATH_PREFIX = '/mobify/proxy'
// All these values MUST be lower case
export const CONTENT_TYPE = 'content-type'
export const CONTENT_ENCODING = 'content-encoding'
export const X_ORIGINAL_CONTENT_TYPE = 'x-original-content-type'
export const X_MOBIFY_QUERYSTRING = 'x-mobify-querystring'
export const X_MOBIFY_FROM_CACHE = 'x-mobify-from-cache'
export const X_ENCODED_HEADERS = 'x-encoded-headers'
export const SET_COOKIE = 'set-cookie'
export const CACHE_CONTROL = 'cache-control'
export const NO_CACHE = 'max-age=0, nocache, nostore, must-revalidate'
export const CONTENT_SECURITY_POLICY = 'content-security-policy'
export const STRICT_TRANSPORT_SECURITY = 'strict-transport-security'
/** * @deprecated Use ssr-namespace-paths.slasPrivateProxyPath instead */
export const SLAS_CUSTOM_PROXY_PATH = '/mobify/slas/private'
// Default regex patterns for SLAS token endpoints, used for setting httpOnly session cookies
// Users can override these in their project's ssr.js options.
export const SLAS_TOKEN_RESPONSE_ENDPOINTS = /\/oauth2\/(token|passwordless\/token)$/
// Default regex pattern for the SLAS logout endpoint, used when httpOnly session cookies are enabled
// to inject Bearer token and refresh token from HttpOnly cookies.
// Users can override this in their project's ssr.js options.
export const SLAS_LOGOUT_ENDPOINT = /\/oauth2\/logout/