Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
angular2-weather-widget
Advanced tools
[![npm version](https://img.shields.io/npm/v/angular2-weather-widget.svg)](https://www.npmjs.com/package/angular2-weather-widget) <!-- [![downloads](https://img.shields.io/npm/dt/angular2-weather-widget.svg)](https://www.npmjs.com/package/angular2-weathe
Angular 2+ Weather Widget component for web applications. Easy and Highly customisable.
The Weather Widget package is published on the npm Registry.
Install the package :
npm install angular2-weather-widget --save
Once installed import AngularWeatherWidgetModule
from the installed package into your module as follows:
Import AngularWeatherWidgetModule
into NgModule
in app.module.ts
. Angular's HttpClientModule
and CommonModule
is also required.
import { AngularWeatherWidgetModule } from 'angular2-weather-widget';
import { HttpClientModule } from '@angular/common/http';
import { CommonModule } from '@angular/common';
@NgModule({
// ...
imports: [
AngularWeatherWidgetModule,
HttpClientModule,
CommonModule
]
// ...
})
Add the following component tag in you template (no properties)
<angular-weather-widget
[APIKEY]="APIKEY">
</angular-weather-widget>
Full properties
<angular-weather-widget
[APIKEY]="APIKEY"
[width]="'280px'"
[height]="'auto'"
[backgroundColor]="'#000'"
[isBoxShadow]="true"
[borderRadius]="'5px'"
[locationFontSize]="'40px'"
[locationFontColor]="'#fff'"
[status]="true"
[statusFontColor]="'#fff'"
[statusFontSize]="'18px'"
[temperature]="true"
[isDegree]="true"
[isFahrenheit]="false"
[tempratureFontColor]="'#fff'"
[tempratureFontSize]="'80px'"
[weatherImages]="true"
[weatherImageWidth]="'100px'"
[weatherImageHeight]="'100px'"
[geoLocation]="true"
[location]="''"
[isWind]="true"
[isWindKPH]="true"
[isWindMPH]="false"
[windFontColor]="'#fff'"
[windFontSize]="'20px'">
</angular-weather-widget>
The following list of properties are supported by the component.
Property | Type | Description | Default Value |
---|---|---|---|
APIKEY | String | API key from APIUX | 'APIKEY' |
width | String | Width of the weather card | '280px' |
height | String | Height of the weather card | auto |
backgroundColor | String | Background color of the weather card | '#2a2828' |
isBoxShadow | Boolean | Box shadow of the weather card | true |
borderRadius | String | Border-radius of the weather card | 5px |
locationFontSize | String | Font size of the location text | 40px |
locationFontColor | String | Color of the location text | #fff |
status | Boolean | Current weather status | true |
statusFontSize | String | Font size of the location text | 18px |
statusFontColor | String | Color of the status text | #fff |
temperature | Boolean | Temperature of the location | true |
tempratureFontSize | String | Font size of the temperature text | 80px |
tempratureFontColor | String | Color of the temperature text | #fff |
isDegree | Boolean | Temperature measure format in Degree | true |
isFahrenheit | Boolean | Temperature measure format in Fahrenheit | false |
weatherImages | Boolean | Weather icon | true |
weatherImageWidth | String | Weather icon width | 100px |
weatherImageHeight | String | Weather icon height | 100px |
geoLocation | Boolean | Access/Show weather of the user's location | true |
location | String | Show one specific location's weather | '' |
isWind | Boolean | Wind of the location | true |
windFontSize | String | Font size of the wind text | 20px |
windFontColor | String | Color of the wind text | #fff |
isWindKPH | Boolean | Wind measure foremat in KPH | true |
isWindMPH | Boolean | Wind measure foremat in MPH | false |
npm install
ng serve
for a dev serverhttp://localhost:4200/
MIT License.
FAQs
[![npm version](https://img.shields.io/npm/v/angular2-weather-widget.svg)](https://www.npmjs.com/package/angular2-weather-widget) <!-- [![downloads](https://img.shields.io/npm/dt/angular2-weather-widget.svg)](https://www.npmjs.com/package/angular2-weathe
The npm package angular2-weather-widget receives a total of 11 weekly downloads. As such, angular2-weather-widget popularity was classified as not popular.
We found that angular2-weather-widget demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.