Code Monkey home page Code Monkey logo

Comments (4)

MSNev avatar MSNev commented on May 22, 2024

Yes, this is a compatibility issue with Angular 7.

I am wondering if these are compatibility issues. If so, what versions of AI and the angular plugin should I use for Angular 7?

For Applicaiton Insights you can (should) be able to use any version, however, for the @microsoft/applicationinsights-angularplugin-js this is built using specific version of Angular and is where the issue is coming from.

What you can do for your Angular 7 app is to create your own Angular extension using the code in this repo as a guide, as all of the necessary components to create you own extensions are exported from the main Application Insights code.

from applicationinsights-angularplugin-js.

jonathanblancor avatar jonathanblancor commented on May 22, 2024

@MSNev Thank you for that solution.

So far there is not a lot we need to track.
1- So if I don't use this angular plugin (or my own extension), what functionality would I be missing if just using the AI library on its own instead?
2- I read that setting enableAutoRouteTracking: true would do the route tracking, eliminating some of the need for the angular plugin?

from applicationinsights-angularplugin-js.

MSNev avatar MSNev commented on May 22, 2024

This plugin is really just providing the necessary "Hooks" for

  • Route tracking via the Angular router
  • Catching the Angular error handling to call trackException (via the ErrorService)
  • And handling unloading / unregistering from the events when the SDK is "unloaded"

Simplistically, if your app does change the browser URL (using # of otherwise) so that the locating history API provides the necessary "Page view(s)" for you then the only issue would be the Error Service.
Additional Note: enableAutoRouteTracking WILL cause a new "PageView" for EVERY URL (history) change, so (if) you change the URL (even just to save user input or display a dialog), this will cause multiple Page view events.

from applicationinsights-angularplugin-js.

jonathanblancor avatar jonathanblancor commented on May 22, 2024

Thank you for your help! Closing the ticket.

from applicationinsights-angularplugin-js.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.