How to remove cookies ai_user ai_session completely from client side app insights

1.9k Views Asked by At

_Layout.cshtml

@inject Microsoft.ApplicationInsights.AspNetCore.JavaScriptSnippet JavaScriptSnippet


<!DOCTYPE html>
<html>
<head> 
    @Html.Raw(JavaScriptSnippet.FullScript)
</head>
...

When I remove the above code the cookies are still there in the browser (before I started debugging mode I deleted all cookies in the browser :-) )

I do not need the clientside app insights JS library. I use app insights only server side.

How do I get rid of those cookies totally?

UPDATE

I use asp.net core 1.1 and I can NOT update!

1

There are 1 best solutions below

0
Frank Campbell On

Normally, we use the isCookieUseDisabled to control cookies even though you think it's stupid.

If it does not meet your need, please raise an issue in application insights github.