Hello everyone,
I have built a Vue app, and when I build the application using npm run build, the app builds successfully. However, when I look into the Google Chrome inspector, I notice something.
49650: function(e, t, r) {
var i = r(74971);
function a(e, t) {
if ("string" === typeof e) {
if (["legacy", "regional"].indexOf(e.toLowerCase()) >= 0)
return e.toLowerCase();
throw i.util.error(new Error, t)
}
}
function s(e, t) {
var r;
if (e = e || {},
e[t.clientConfig] && (r = a(e[t.clientConfig], {
code: "InvalidConfiguration",
message: 'invalid "' + t.clientConfig + '" configuration. Expect "legacy" or "regional". Got "' + e[t.clientConfig] + '".'
}),
r))
return r;
if (!i.util.isNode())
return r;
if (Object.prototype.hasOwnProperty.call({
VUE_APP_URL_API: "https://ms-brick.loc:31060/api",
NODE_ENV: "production",
BASE_URL: "/"
}, t.env)) {
var s = {
VUE_APP_URL_API: "https://ms-brick.loc:31060/api",
NODE_ENV: "production",
BASE_URL: "/"
}[t.env];
if (r = a(s, {
code: "InvalidEnvironmentalVariable",
message: "invalid " + t.env + ' environmental variable. Expect "legacy" or "regional". Got "' + {
VUE_APP_URL_API: "https://ms-brick.loc:31060/api",
NODE_ENV: "production",
BASE_URL: "/"
}[t.env] + '".'
}),
r)
return r
}
var o = {};
try {
var n = i.util.getProfilesFromSharedConfig(i.util.iniLoader);
o = n[{
VUE_APP_URL_API: "https://ms-brick.loc:31060/api",
NODE_ENV: "production",
BASE_URL: "/"
}.AWS_PROFILE || i.util.defaultProfile]
} catch (p) {}
if (o && Object.prototype.hasOwnProperty.call(o, t.sharedConfig)) {
var u = o[t.sharedConfig];
if (r = a(u, {
code: "InvalidConfiguration",
message: "invalid " + t.sharedConfig + ' profile config. Expect "legacy" or "regional". Got "' + o[t.sharedConfig] + '".'
}),
r)
return r
}
return r
}
e.exports = s
},
The app works perfectly, but I'm wondering about this because I can see my environment variables explicitly, like this VUE_APP_URL_API and not obfuscated
Could anyone help me to fix this? I'll appreciate.
I hope the value of each variable is obfuscated