Skip to content

Commit

Permalink
reenable ai (#246)
Browse files Browse the repository at this point in the history
* reenable ai

* updated ts

* updated modules
  • Loading branch information
pelikhan authored Jan 3, 2023
1 parent 102d08b commit f489584
Show file tree
Hide file tree
Showing 4 changed files with 152 additions and 1,933 deletions.
2 changes: 1 addition & 1 deletion jacdac-ts
Submodule jacdac-ts updated 1 files
+1 −1 jacdac-spec
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"@jscad/modeling": "^2.10.0",
"@jscad/stl-serializer": "^2.1.12",
"@mdx-js/react": "^2.1.3",
"@microsoft/applicationinsights-web": "^2.8.9",
"@mui/icons-material": "^5.10.6",
"@mui/lab": "^5.0.0-alpha.102",
"@mui/material": "^5.10.8",
Expand Down
9 changes: 2 additions & 7 deletions src/components/hooks/useAnalytics.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
import React, { Component, ErrorInfo, ReactNode } from "react"
/*
import {
ApplicationInsights,
SeverityLevel,
} from "@microsoft/applicationinsights-web"
*/


export type EventProperties = Record<string, string | number | boolean>
const sha = process.env.GATSBY_GITHUB_SHA
Expand Down Expand Up @@ -40,8 +39,6 @@ const appInsights: AppInsightsApp =
INSTRUMENTATION_KEY &&
// ignore dev environment
!/http:\/\/localhost/.test(window.location.href) &&
undefined
/*
new ApplicationInsights({
config: {
instrumentationKey: INSTRUMENTATION_KEY,
Expand All @@ -52,7 +49,7 @@ const appInsights: AppInsightsApp =
enableSessionStorageBuffer: false,
autoTrackPageVisitTime: true,
},
})*/
})
if (appInsights) {
appInsights.loadAppInsights()
appInsights.addTelemetryInitializer(envelope => {
Expand Down Expand Up @@ -84,13 +81,11 @@ const trackError: (exception: Error, properties?: EventProperties) => void =
: () => {}

const severities = {
/*
debug: SeverityLevel.Verbose,
warn: SeverityLevel.Warning,
error: SeverityLevel.Error,
info: SeverityLevel.Information,
log: SeverityLevel.Information,
*/
}
const trackTrace: (
message: string,
Expand Down
Loading

0 comments on commit f489584

Please sign in to comment.