diff --git a/js/src/collapse.js b/js/src/collapse.js
index 693e7ee2c8802a5a73f123053a721362c7e68d07..e569d998194c8964ab272e4f5830118dc80d2ff3 100644
--- a/js/src/collapse.js
+++ b/js/src/collapse.js
@@ -342,7 +342,7 @@ class Collapse {
     const _config = {
       ...Default,
       ...Manipulator.getDataAttributes(element),
-      ...typeof config === 'object' && config ? config : {}
+      ...(typeof config === 'object' && config ? config : {})
     }
 
     if (!data && _config.toggle && typeof config === 'string' && /show|hide/.test(config)) {
diff --git a/js/src/dropdown.js b/js/src/dropdown.js
index 539f9e7a44e8874d47150b8988485116cf8ff7a7..4af48cadb862302da20a8dde2aa585fa05aa743d 100644
--- a/js/src/dropdown.js
+++ b/js/src/dropdown.js
@@ -303,7 +303,7 @@ class Dropdown {
       offset.fn = data => {
         data.offsets = {
           ...data.offsets,
-          ...this._config.offset(data.offsets, this._element) || {}
+          ...(this._config.offset(data.offsets, this._element) || {})
         }
 
         return data
diff --git a/js/src/modal.js b/js/src/modal.js
index 8c6617650d26459cf7ad3d881df4d2a9a12793df..1285793f36e73860fd31326bb2b6d1c30e0ac6b3 100644
--- a/js/src/modal.js
+++ b/js/src/modal.js
@@ -544,7 +544,7 @@ class Modal {
       const _config = {
         ...Default,
         ...Manipulator.getDataAttributes(this),
-        ...typeof config === 'object' && config ? config : {}
+        ...(typeof config === 'object' && config ? config : {})
       }
 
       if (!data) {
diff --git a/js/src/scrollspy.js b/js/src/scrollspy.js
index 6f7dd04f270320d5f6503bd375cac658816f365f..108b6f067bfb53a92bd6eefa191160b0fe08660d 100644
--- a/js/src/scrollspy.js
+++ b/js/src/scrollspy.js
@@ -160,7 +160,7 @@ class ScrollSpy {
   _getConfig(config) {
     config = {
       ...Default,
-      ...typeof config === 'object' && config ? config : {}
+      ...(typeof config === 'object' && config ? config : {})
     }
 
     if (typeof config.target !== 'string' && isElement(config.target)) {
diff --git a/js/src/toast.js b/js/src/toast.js
index fd9976fb974a52a92f702e83d1507e28cff317dd..30f90c29575aea712171b3daa2ecfbaeb12f9662 100644
--- a/js/src/toast.js
+++ b/js/src/toast.js
@@ -170,7 +170,7 @@ class Toast {
     config = {
       ...Default,
       ...Manipulator.getDataAttributes(this._element),
-      ...typeof config === 'object' && config ? config : {}
+      ...(typeof config === 'object' && config ? config : {})
     }
 
     typeCheckConfig(NAME, config, this.constructor.DefaultType)
diff --git a/js/src/tooltip.js b/js/src/tooltip.js
index d8d92f57d1f60c85d382098688156de99ac4eb02..9ad73328bed9fb214a8c9da82756ed58f517c3fb 100644
--- a/js/src/tooltip.js
+++ b/js/src/tooltip.js
@@ -491,7 +491,7 @@ class Tooltip {
       offset.fn = data => {
         data.offsets = {
           ...data.offsets,
-          ...this.config.offset(data.offsets, this.element) || {}
+          ...(this.config.offset(data.offsets, this.element) || {})
         }
 
         return data
@@ -689,7 +689,7 @@ class Tooltip {
     config = {
       ...this.constructor.Default,
       ...dataAttributes,
-      ...typeof config === 'object' && config ? config : {}
+      ...(typeof config === 'object' && config ? config : {})
     }
 
     if (typeof config.delay === 'number') {