This repository is for the codebase of a lightweight Angular v7 web component that makes GET requests to specified URLs.
This web component is used on the PDBe-KB Aggregated Views of Proteins to generate web traffic for PDBe-KB partner resources who have contributed annotations for a particular protein of interest.
Get the code and install dependencies
git clone https://github.com/PDBe-KB/component-ping-resources.git
cd component-ping-resources
npm i
Running the app
ng serve
Running tests
ng test
The main template (i.e. index.html
by default) should also have the following CSS imports:
<link rel="stylesheet" href="https://ebi.emblstatic.net/web_guidelines/EBI-Framework/v1.3/css/ebi-global.css" type="text/css" media="all"/>
<link rel="stylesheet" href="https://ebi.emblstatic.net/web_guidelines/EBI-Icon-fonts/v1.3/fonts.css" type="text/css" media="all"/>
<link rel="stylesheet" href="https://ebi.emblstatic.net/web_guidelines/EBI-Framework/v1.3/css/theme-pdbe-green.css" type="text/css" media="all"/>
The pinging component can be added to any Angular v6 apps.
Import the component in app.module.ts
by default.
import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';
import { AppComponent } from './app.component';
import { PingComponent } from './ping/ping.component';
@NgModule({
declarations: [
AppComponent,
PingComponent
],
imports: [
BrowserModule
],
providers: [],
bootstrap: [AppComponent]
})
export class AppModule { }
Adding the pinging component to a template:
<app-ping [pingUrlData]=""></app-ping>
The data model for the input data is described in
src/app/ping/ping.models.ts
[
{
"resourceName": "3Dcomplex",
"url": "https://shmoo.weizmann.ac.il/elevy/3dcomplexV6/Home.cgi"
}
]
We use SemVer for versioning. For the versions available, see the tags on this repository.
See also the list of contributors who participated in this project.
This project is licensed under the EMBL-EBI License - see the LICENSE file for details
We would like to thank the PDBe team and the PDBe-KB partner resources for their feedback and contributions.