diff --git a/docusaurus.config.js b/docusaurus.config.js index b4808c2925..f48e699dda 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -17,6 +17,17 @@ const config = { deploymentBranch: 'gh-pages', trailingSlash: false, + clientModules: [ + require.resolve('./embedValue.js'), + ], + scripts: [ + { + src: 'https://reiki.web3go.xyz/aiweb/embed.js', + id: "F03vpUuT3em6KopZ", + defer: true, + }, + ], + plugins: [ require.resolve("docusaurus-plugin-image-zoom"), diff --git a/embedValue.js b/embedValue.js new file mode 100644 index 0000000000..1a6bb8ae60 --- /dev/null +++ b/embedValue.js @@ -0,0 +1,9 @@ +import ExecutionEnvironment from "@docusaurus/ExecutionEnvironment"; + +if (ExecutionEnvironment.canUseDOM) { + // Load Web3Go bot config as soon as site loads in the browser. + window.dinChatbotConfig = { + token: "F03vpUuT3em6KopZ", + api: "https://reiki.web3go.xyz/aiweb", + }; +} \ No newline at end of file