This package has been deprecated

Author message:

Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

aaot-json

1.0.1 • Public • Published

And another Translator with JSON Backend (aaot-json)

Localizer with Jquery and JSON Backend

Setup

Dependencies

  1. JQuery: https://jquery.com/
  2. JS-Cookie: https://github.com/js-cookie/js-cookie

Installation

  1. Download Git Repo
  2. Include Script in your Project

How to use

Setup

localize.url = "yourapi/translation/&lang&"; // &lang& get replaced by the Script with the language
localize.fallBack = "de";
localize.langSupported = ["en", "de"];
localize.cookieExpires = 3; // Default: 7 (Days)

localize.successCallback = function() {..};
localize.errorCallback = function() {...};
localize.beforeSwitch = function() {...};
localize.debug = true;

Run Localizer

localize.setup();

Switch Language

localize.switch("de");

After switching the Language the Script calls automatically localize.setup()

Note

This Script is currently in Development.

not working Things

  • Load from a File

Package Sidebar

Install

npm i aaot-json

Weekly Downloads

1

Version

1.0.1

License

ISC

Unpacked Size

99.4 kB

Total Files

9

Last publish

Collaborators

  • yannikg