typograf-api
v1.0.1
Published
Typography of text with the help of the Typograf.ru's API (Russian language)
Downloads
6
Readme
Typograf-api
Typography of the text using the web service Typograf.ru
Installation
npm install typograf-api
How to use it
var Handler = function(text,err)
{
document.getElementById('jstypo_text').value= text;// вывод в textarea
document.getElementById("text").innerHTML = text;
//text = <p>На лесопилку завезли 32 м³ леса, из которых 4 м³
//пустили под распил на 25 мм доски, длинной по 6 м.</p>
}
var str = document.getElementById('jstypo_text').value;
//str = 'На лесопилку завезли 32 м3 леса, из которых 4м3 пустили
//под распил на 25мм доски, длинной по 6м.';
textTypography(str,Handler);
In case of an error, the same text will be returned. Information about the error that occurred can be obtained from the second argument of the handler.