@nfreear/data
v0.8.0
Published
Collated JSON data, sample data, proverbs, quotes, English and Chinese.
Downloads
6
Readme
@nfreear/data
Collated data, sample data, proverbs, quotes, English and Chinese.
In JSON
format.
Used by nick-bot.
The copyright in the content is owned by the authors, individuals, and publishers of each work collated here.
Usage
const { BBC_WEATHER_LOCATIONS } = require('@nfreear/data');
const location = BBC_WEATHER_LOCATIONS.data.find(loc => loc.en === placeName);
if (location) {
const placeId = location.id;
// ... Do something ...
}
Example schema
{
"meta": {
"title": "Title of the work",
"x-source": "https://example/path/to/the/source",
"author": "A.N.Author",
"copyright": "© A Publisher / A.N.Owner.",
"locales": [ "zh-cn", "en", "x-pinyin" ],
"properties": [ "id", "#" ]
},
"#": [
"A comment or note."
],
"data": [
{
"id": 123,
"zh-cn": "千里之行,始於足下",
"x-pinyin": "Qiānlǐ zhī xíng, shǐyú zú xià. Laozi.",
"en": "Each 10,000 mile journey begins with just 1 step"
}
// ...
]
}