Skip to content
This repository has been archived by the owner on Jul 15, 2020. It is now read-only.

Commit

Permalink
Merge pull request #3 from coveoben/patch-1
Browse files Browse the repository at this point in the history
Fix issue with undefined 'salesforce' variable.

Fix #1
  • Loading branch information
olamothe committed Feb 8, 2018
2 parents 19f8093 + d691d6d commit 4c63ae9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions generators/typescript/templates/webpack.config.js
Expand Up @@ -8,7 +8,7 @@ const plugins = [];
if (minimize) {
plugins.push(new webpack.optimize.UglifyJsPlugin());
}
<% if(salesforce) { %>
<% if (!(typeof salesforce === 'undefined' || salesforce === null)) { %>
const coveoComponentMock = `
<script src="../vendor/coveo/js/CoveoJsSearch.Lazy.js"></script>
<script src="../vendor/coveo/js/templates/templates.js"></script>
Expand All @@ -23,7 +23,7 @@ if (minimize) {

if (!production) {
plugins.push(new webpack.HotModuleReplacementPlugin());
<% if(salesforce) { %>
<% if (!(typeof salesforce === 'undefined' || salesforce === null)) { %>
plugins.push(new VisualforceHtmlPlugin({
SalesforceContext: {
CustomModifiers: {
Expand Down Expand Up @@ -62,4 +62,4 @@ module.exports = {
},
plugins: plugins,
bail: true
};
};

0 comments on commit 4c63ae9

Please sign in to comment.