How to trace angular app to know which component is executed when do some action ?

45 views
Skip to first unread message

ahmed elbarbary

unread,
Nov 16, 2019, 7:33:25 PM11/16/19
to Angular and AngularJS discussion
I work on angular 7 project integrated with asp.net core 2.2 API

this Angular  project done by another persons and i dont know any thing on project

I need to modify left side menu and what component called when click on any item on menu 

but i need any tools or any thing help me to show component called when click item on menu 

to can modify on these components .

so that what i do please ?

Arnaud Deman

unread,
Nov 18, 2019, 10:54:51 AM11/18/19
to Angular and AngularJS discussion
Hi Ahmed,

One possibility is to locate the component via the inspector in your browser.
With the tag you can determine the selector, app-dashboard-item in this exemple:
<app-dashboard-item _ngcontent-mah-c35="" _nghost-mah-c46="" ng-reflect-dashboard-item="[object Object]" (...)>

This selector will help you to locate the component in the project and you can then look in the template and in the component itself to determine what is triggered on click event.

Regards,
Arnaud.
Reply all
Reply to author
Forward
0 new messages