Generates fake language (longer or shorter) from existing localisation file, preserving inline HTML.
LongLang is designed to facilitate multi-national application and website testing by generating a fake localisation file that is longer (or shorter) than the source localisation (e.g. English).
By generating the longer, fake language, you can easily see whether the layout adapts well or if it needs tweaks.
LongLang begins all copy with "S" after which "X"s follow, and appends "E" at the end so you can easily notice whether something is timmed / cropped or if the copy renders well.
LongLang also preserves inline HTML so no tags, attributes or class names will be altered.
LongLang is compatible with AngularJS's ng-translate, i18next and many others.
npm install -g longlang
longlang inputFile [--scale=int]
path to the input JSON file with the original localisation.
copy length multiplier. 1 = same length, 2 = twice as long, 0.5 = 50% shorter
Output will be saved to your current working directory as longlang.json.
longlang fr.json --scale=2.5
longlang source.json --scale=2