
Security News
Potemkin Understanding in LLMs: New Study Reveals Flaws in AI Benchmarks
New research reveals that LLMs often fake understanding, passing benchmarks but failing to apply concepts or stay internally consistent.
datapoint-js
Advanced tools
A JavaScript library for accessing weather data via the [Met Office](http://www.metoffice.gov.uk/)'s open data API known as [DataPoint](http://www.metoffice.gov.uk/datapoint).
A JavaScript library for accessing weather data via the Met Office's open data API known as DataPoint.
Disclaimer: This module is in no way part of the DataPoint project/service. This module is intended to simplify the use of DataPoint for JavaScript projects. No support for this module is provided by the Met Office and may break as the DataPoint service grows/evolves. The author will make reasonable efforts to keep it up to date and fully featured.
npm install datapoint-js
bower install datapoint-js
Download the contents of either /src
(for node) or /dist/browser
(for browser) and include them in your project.
var datapoint = require('datapoint-js')
datapoint.set_key("aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee")
site = datapoint.get_nearest_forecast_site(-0.124626, 51.500728)
forecast = datapoint.get_forecast_for_site(site.id, "3hourly")
current_timestep = forecast.days[0].timesteps[0]
console.log("Temperature is " + current_timestep.temperature.value + "°" + current_timestep.temperature.units + " in " + site.name)
Temperature is 15°C in London
<html>
<head>
<title>Datapoint test</title>
</head>
<body>
<h1>Weather</h1>
<p id="weather">Loading...</p>
<script src="../dist/browser/datapoint.js"></script>
<script>
datapoint.set_key("aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee");
site = datapoint.get_nearest_forecast_site(-0.124626, 51.500728);
forecast = datapoint.get_forecast_for_site(site.id);
current_timestep = forecast.days[0].timesteps[0];
document.getElementById("weather").innerHTML =
"Temperature is " + current_timestep.temperature.value + "°" + current_timestep.temperature.units + " in " + site.name;
</script>
</body>
</html>
The contents of the <p>
block is replaced with Temperature is 15°C in London
.
Please feel free to submit issues and pull requests.
To work on the project simply clone the project and run npm install
.
This project uses gulp as its task runner and can be used to browserify the code and generate the documentation.
Documentation is automatically generated using JSDoc and is stored in docs.
To regenerate the documentation simply run
gulp document
GPL v3
FAQs
A JavaScript library for accessing weather data via the [Met Office](http://www.metoffice.gov.uk/)'s open data API known as [DataPoint](http://www.metoffice.gov.uk/datapoint).
We found that datapoint-js 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
New research reveals that LLMs often fake understanding, passing benchmarks but failing to apply concepts or stay internally consistent.
Security News
Django has updated its security policies to reject AI-generated vulnerability reports that include fabricated or unverifiable content.
Security News
ECMAScript 2025 introduces Iterator Helpers, Set methods, JSON modules, and more in its latest spec update approved by Ecma in June 2025.