Browse Source

Merge pull request #15147 from hashicorp/backport/ui/fix-auto-import-public-url/unduly-enjoyed-bream

Backport of ui: fix - customize ember-auto-import publicAssetURL in production into release/1.14.x
pull/15161/head
Michael Klein 2 years ago committed by GitHub
parent
commit
3c948b74df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      ui/packages/consul-ui/ember-cli-build.js

2
ui/packages/consul-ui/ember-cli-build.js

@ -17,6 +17,7 @@ module.exports = function (defaults, $ = process.env) {
$ = utils.env($);
const env = EmberApp.env();
const isProd = ['production'].includes(env);
const prodlike = ['production', 'staging'];
const devlike = ['development', 'staging'];
const sourcemaps = !['production'].includes(env) && !$('BABEL_DISABLE_SOURCEMAPS', false);
@ -197,6 +198,7 @@ module.exports = function (defaults, $ = process.env) {
autoImport: {
// allows use of a CSP without 'unsafe-eval' directive
forbidEval: true,
publicAssetURL: isProd ? '{{.ContentPath}}assets' : undefined,
},
codemirror: {
keyMaps: ['sublime'],

Loading…
Cancel
Save