1
0
Fork 0
mirror of https://github.com/codex-team/codex.docs.git synced 2025-08-07 06:25:21 +02:00

client side error tracking refactor

This commit is contained in:
Umang G. Patel 2022-07-09 00:12:29 +05:30
parent ac4feda9cb
commit 4d19c4aca0
2 changed files with 4 additions and 2 deletions

View file

@ -12,7 +12,7 @@
<script>
window.config = {
misprintsChatId: "{{ config.misprintsChatId }}",
hawkToken:"{{ config.twigAppHawkToken }}",
hawkClientToken:"{{ config.hawkClientToken }}",
};
</script>
<body>

View file

@ -31,7 +31,9 @@ class Docs {
this.page = new Page();
this.extensions = new Extensions();
this.sidebar = new Sidebar();
this.hawk = new HawkCatcher(window.config.hawkToken);
if (window.config.hawkClientToken) {
this.hawk = new HawkCatcher(window.config.hawkClientToken);
}
document.addEventListener('DOMContentLoaded', (event) => {
this.docReady();