Skip to content

Commit 21829e1

Browse files
committed
Updating insertCallToAction object to be consistent with API.creat(), and switching some content to single quotes to be more consistent
1 parent 039a851 commit 21829e1

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

source/includes/_methods.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,12 @@ Please see the <a href="#event-subscriptions">specific event documentation</a> f
2323
const API = await APILoader.create(document.currentScript);
2424
API.insertCallToAction('button', 'value-a-trade', meta => {
2525
return {
26-
"type": "default",
27-
"href": "https://www.yourdomain.com/value-a-trade/?vin=" + meta.vin,
28-
"target": "_blank",
29-
"text": {
30-
"en_US": "Value My Trade",
31-
"fr_CA": "Valeur mon commerce"
26+
type: 'default',
27+
href: 'https://www.yourdomain.com/value-a-trade/?vin=' + meta.vin,
28+
target: '_blank',
29+
text: {
30+
en_US: 'Value My Trade',
31+
fr_CA: 'Valeur mon commerce'
3232
}
3333
}
3434
});
@@ -132,13 +132,13 @@ After creating the callback object, you must then return it for the API to creat
132132
API.insertCallToActionOnce('button', 'value-a-trade', meta => {
133133
if (serviceData.hasOwnProperty(meta.vin)) {
134134
return {
135-
"type": "default",
136-
"classes": "custom-class1 custom-class2",
137-
"href": "https://www.yourdomain.com/value-a-trade/?vin=" + meta.vin,
138-
"target": "_blank",
139-
"text": {
140-
"en_US": "Value My Trade",
141-
"fr_CA": "Valeur mon commerce"
135+
type: 'default',
136+
classes: 'custom-class1 custom-class2',
137+
href: 'https://www.yourdomain.com/value-a-trade/?vin=' + meta.vin,
138+
target: '_blank',
139+
text: {
140+
en_US: 'Value My Trade',
141+
fr_CA: 'Valeur mon commerce'
142142
}
143143
}
144144
} else {

0 commit comments

Comments
 (0)