Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
johnnys-weather
Advanced tools
Readme
You can get all informations available in the xml as explain in th Yahoo! doc here : http://developer.yahoo.com/weather.
An example of how to get the weather based on location.
var weather = require('weather');
var params = {
location : 'Melbourne',
unit : 'f', // Celcius(default, "c") or Fahrenheit ("f")
appid : "MyYahhoAppId",
logging : false //Debug info or not
}
weather(params, function(data) {
if (data.condition.temp > 30) {
console.log("Damn it's hot!");
}
});
###Example JSON result:
{
date: 'Thu, 10 Oct 2013 5:29 am AEST',
location: {
city: 'Melbourne',
region: 'VIC',
country: 'Australia',
lat: '-37.87',
long: '145.1'
},
units: {
temperature: 'F',
distance: 'mi',
pressure: 'in',
speed: 'mph'
},
wind: {
chill: '57',
direction: '50',
speed: '8'
},
atmosphere: {
humidity: '82',
visibility: '6.21',
pressure: '29.59',
rising: '0'
},
astronomy: {
sunrise: '5:42 am',
sunset: '6:30 pm'
},
condition: {
text: 'Showers in the Vicinity',
code: '29',
temp: '57',
date: 'Thu, 10 Oct 2013 5:29 am AEST'
},
description: '\n<img src="http://l.yimg.com/a/i/us/we/52/29.gif"/><br />\n<b>Current Conditions:</b><br />\nShowers in the Vicinity, 57 F<BR />\n<BR /><b>Forecast:</b><BR />\nThu - PM Light Rain. High: 62 Low: 45<br />\nFri - Partly Cloudy. High: 70 Low: 48<br />\nSat - Mostly Sunny. High: 78 Low: 50<br />\nSun - Partly Cloudy. High: 57 Low: 42<br />\nMon - Partly Cloudy. High: 62 Low: 42<br />\n<br />\n<a href="http://us.rd.yahoo.com/dailynews/rss/weather/Melbourne__AU/*http://weather.yahoo.com/forecast/ASXX0075_f.html">Full Forecast at Yahoo! Weather</a><BR/><BR/>\n(provided by <a href="http://www.weather.com" >The Weather Channel</a>)<br/>\n',
days:
[ { day: 'Thu',
date: '10 Oct 2013',
low: '45',
high: '62',
text: 'PM Light Rain',
code: '11' },
{ day: 'Fri',
date: '11 Oct 2013',
low: '48',
high: '70',
text: 'Partly Cloudy',
code: '30' },
{ day: 'Sat',
date: '12 Oct 2013',
low: '50',
high: '78',
text: 'Mostly Sunny',
code: '34' },
{ day: 'Sun',
date: '13 Oct 2013',
low: '42',
high: '57',
text: 'Partly Cloudy',
code: '30' },
{ day: 'Mon',
date: '14 Oct 2013',
low: '42',
high: '62',
text: 'Partly Cloudy',
code: '30' }
]
}
Licensed under the MIT License
FAQs
Yahoo weather API wrapper for node
The npm package johnnys-weather receives a total of 1 weekly downloads. As such, johnnys-weather popularity was classified as not popular.
We found that johnnys-weather 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
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.