⚡ (pixel) Add skip initialization option
This commit is contained in:
@@ -8,10 +8,6 @@ The Google Analytics integration block allows you to track a Google Analytics ev
|
||||
alt="Google Analytics block"
|
||||
/>
|
||||
|
||||
:::note
|
||||
This block is not executed in Preview mode. To test it, you need to launch the published bot.
|
||||
:::
|
||||
|
||||
When your flow contains a Google Analytics block, under the hood it:
|
||||
|
||||
- Initialize GA and track a "Page view" event on page load.
|
||||
|
||||
@@ -8,10 +8,6 @@ The Pixel integration block allows you to add a Meta pixel to your bot and track
|
||||
alt="Pixel block"
|
||||
/>
|
||||
|
||||
:::note
|
||||
This block is not executed in Preview mode. To test it, you need to launch the published bot.
|
||||
:::
|
||||
|
||||
When your flow contains a pixel block, under the hood it:
|
||||
|
||||
- Initialize the pixel and track "PageView" event on page load.
|
||||
|
||||
@@ -37,7 +37,7 @@ You can tweak `3000` (3s) to your liking.
|
||||
|
||||
In the Metadata section, you can customize how the preview card will look if you share your bot URL on social media for example.
|
||||
|
||||
You can also add some custom head code to add third-party scripts like a Facebook pixel for example.
|
||||
You can also add some custom head code to add third-party scripts.
|
||||
|
||||
### Google Tag Manager
|
||||
|
||||
|
||||
@@ -184,6 +184,28 @@ typebot-bubble::part(preview-message) {
|
||||
}
|
||||
```
|
||||
|
||||
## Callbacks
|
||||
|
||||
If you need to trigger events on your parent website when the user interact with the bot, you can use the following callbacks:
|
||||
|
||||
```js
|
||||
Typebot.initStandard({
|
||||
typebot: 'my-typebot',
|
||||
onNewInputBlock: (inputBlock) => {
|
||||
console.log('New input block displayed', inputBlock.id)
|
||||
},
|
||||
onAnswer: (answer) => {
|
||||
console.log('Answer received', answer.message, answer.blockId)
|
||||
},
|
||||
onInit: () => {
|
||||
console.log('Bot initialized')
|
||||
},
|
||||
onEnd: () => {
|
||||
console.log('Bot ended')
|
||||
},
|
||||
})
|
||||
```
|
||||
|
||||
## Additional configuration
|
||||
|
||||
You can prefill the bot variable values in your embed code by adding the `prefilledVariables` option. Here is an example:
|
||||
|
||||
Reference in New Issue
Block a user