I am using the login()
function in my Chrome extension. I am trying to call the function when form submit. But, the function is not called in a Chrome extension. But, when I run the project in an Angular way the function is called.
This is my HTML code.
<form (ngSubmit)="login()" id="SignIn">
and my ts code is
login(){
alert("form submitted");
}
I referred to the following blog link angular 2 chrome extension
and my manifest file is
{
"manifest_version": 2,
"name": "chrome extension",
"description": "This extension will used to simplify the project",
"version": "1.0",
"browser_action": {
"default_icon": "icon.png",
"default_popup": "popup.html"
},
"permissions": [
"http://example.com/*",
"activeTab"
]
}
I want to handle the events with in a component.i don't want to the another script file.