From b115fdefbc248f9455b6766cfc9de4d6286848ae Mon Sep 17 00:00:00 2001 From: Harshal Sheth Date: Mon, 8 Jul 2024 16:12:30 -0700 Subject: [PATCH] docs: add new js snippet (#10846) --- docs-website/docusaurus.config.js | 5 +++++ docs-website/static/scripts/rb2b.js | 1 + 2 files changed, 6 insertions(+) create mode 100644 docs-website/static/scripts/rb2b.js diff --git a/docs-website/docusaurus.config.js b/docs-website/docusaurus.config.js index 1b05efe8c4d15..df23d1bbf38ba 100644 --- a/docs-website/docusaurus.config.js +++ b/docs-website/docusaurus.config.js @@ -19,6 +19,11 @@ module.exports = { async: true, defer: true, }, + { + src: "/scripts/rb2b.js", + async: true, + defer: true, + } ], noIndex: isSaas, customFields: { diff --git a/docs-website/static/scripts/rb2b.js b/docs-website/static/scripts/rb2b.js new file mode 100644 index 0000000000000..684c981116bd9 --- /dev/null +++ b/docs-website/static/scripts/rb2b.js @@ -0,0 +1 @@ +!function () {var reb2b = window.reb2b = window.reb2b || [];if (reb2b.invoked) return;reb2b.invoked = true;reb2b.methods = ["identify", "collect"];reb2b.factory = function (method) {return function () {var args = Array.prototype.slice.call(arguments);args.unshift(method);reb2b.push(args);return reb2b;};};for (var i = 0; i < reb2b.methods.length; i++) {var key = reb2b.methods[i];reb2b[key] = reb2b.factory(key);}reb2b.load = function (key) {var script = document.createElement("script");script.type = "text/javascript";script.async = true;script.src = "https://s3-us-west-2.amazonaws.com/b2bjsstore/b/" + key + "/reb2b.js.gz";var first = document.getElementsByTagName("script")[0];first.parentNode.insertBefore(script, first);};reb2b.SNIPPET_VERSION = "1.0.1";reb2b.load("8XOE9GHYQ3OM");}(); \ No newline at end of file