1.0.5 • Published 1 year ago

fit-my-text v1.0.5

Weekly downloads
-
License
ISC
Repository
github
Last release
1 year ago

Summary

A package that allows you to adjust the text to the width of the container. Decreases or increases the font size to fit the text in the container.

Install via NPM

  npm install fit-my-text

Usage

  import fitMyText from 'fit-my-text';

  fitMyText(element, options);

Options

OptionDefaultDescription
elementquerySelector for element (required)
min16The minimum font size in pixels
max512The maximum font size in pixels
selectorTypesingleDefines if you use single element or multiple elements (may be 'single' or 'multiple')

Options object

{
  min: 16,
  max: 512,
  selectorType: 'single'
}
1.0.5

1 year ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

0.0.5

1 year ago

0.0.4

1 year ago

0.0.3

1 year ago

0.0.2

1 year ago

0.0.1

1 year ago

1.0.0

1 year ago