Ensure that foreground and background color combinations meet WCAG2 guidelines.
The third argument is an object.
the 'level' property states 'AA' or 'AAA' - if missing or invalid, it defaults to 'AA';
the 'size' property states 'large' or 'small' - if missing or invalid, it defaults to 'small'.
If the entire object is absent, isReadable defaults to {level:"AA",size:"small"}.
Ensure that foreground and background color combinations meet WCAG2 guidelines. The third argument is an object. the 'level' property states 'AA' or 'AAA' - if missing or invalid, it defaults to 'AA'; the 'size' property states 'large' or 'small' - if missing or invalid, it defaults to 'small'. If the entire object is absent, isReadable defaults to {level:"AA",size:"small"}.
Example