isVariableWidth.js 256 B

1234567
  1. import assertString from './util/assertString';
  2. import { fullWidth } from './isFullWidth';
  3. import { halfWidth } from './isHalfWidth';
  4. export default function isVariableWidth(str) {
  5. assertString(str);
  6. return fullWidth.test(str) && halfWidth.test(str);
  7. }