JsCould is a fork of the jQCloud library that removes the use of Jquery but instead use Typescript.
npm install js-word-cloud
Include the css file in your html file:
<link rel="stylesheet" type="text/css" href="node_modules/js-word-cloud/dist/jqcloud.css">
Import the library in your javascript file:
import jscloud from 'js-word-cloud';
jscloud(document.getElementById('wc'), [
{ text: 'Lorem', weight: 13 },
{ text: 'Ipsum', weight: 10.5 },
{ text: 'Dolor', weight: 9.4 },
{ text: 'Sit', weight: 8 },
{ text: 'Amet', weight: 6.2 },
{ text: 'Consectetur', weight: 5 },
{ text: 'Adipiscing', weight: 5 },
], {
width: 500,
height: 350,
});
For proper documentation, please refer to the original jQCloud documentation. http://mistic100.github.io/jQCloud
This library is available under the MIT license.