web-literacy-client
v1.1.1
Published
This is a utility to map each version of the Web Literacy Map to a set of machine-readable tags.
Downloads
6
Readme
Web Literacy Client
This is a utility to map each version of the Web Literacy Map to a set of machine-readable tags.
The goal of this repository is to:
- Store version history for the map with tags
- Provide localized versions of each tag via Transifex
- Provide translations for deprecated tags in older versions of the map by mapping them to new literacies
- Provide support for applications using i18n that need to use the Web literacy Map
Creating a new version
- Edit
src/weblitmap.json
. Make sure you update the version number. - Run
npm install
, and thengrunt generate
. This will createdist/weblitmap_strings.{{version}}.json
, a Transifex-compatible file. - Commit your changes and tag your release with
npm version {{version}}
.
Downloading new locales
- Run
grunt build
- Your files will get downloaded from Transifex and
dist/web-literacy-client.with-langs.js
will be generated. Hurray!
Integrating the Web Literacy Map with your localized app
TODO: Including locale/
json files
Using the web literacy client in the browser
bower install web-literacy-client
var wlc = new WebLiteracyClient();
wlc.lang('fr');
wlc.all();
wlc.term(someTag);
wlc.description(someTag);
Using the web literacy client in node
npm install web-literacy-client
var WebLiteracyClient = require('web-literacy-client');
var wlc = new WebLiteracyClient();
wlc.lang('fr');
wlc.all();
wlc.term(someTag);
wlc.description(someTag);
Tests and Examples
bower install
to install quint and example dependencies.
See tests/
to run unit tests.
See examples/
for a node and browser example.