Skip to content

atipunov/calculate-size

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

calculate-size Build Status

Install

$ bower install calculate-size

Usage

var size = calculateSize("Hello world!", {
   font: 'Arial',
   fontSize: '12px'
});

console.log(size.width); // 140
console.log(size.height); // 20

Coming soon

  • Integrated caching

About

Calculate the pixel size of a string

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%