Ramda Adjunct 2.33.0

isNotRegExp.js

  1. import { complement } from 'ramda';
  2. import isRegExp from './isRegExp';
  3. /**
  4. * Checks if value is complement of `RegExp` object.
  5. *
  6. * @func isNotRegExp
  7. * @memberOf RA
  8. * @since {@link https://char0n.github.io/ramda-adjunct/2.5.0|v2.5.0}
  9. * @category Type
  10. * @sig * -> Boolean
  11. * @param {*} val The value to test
  12. * @return {boolean}
  13. * @see {@link RA.isRegExp|isRegExp}
  14. * @example
  15. *
  16. * RA.isNotRegExp(1); //=> true
  17. * RA.isNotRegExp(/(?:)/); //=> false
  18. * RA.isNotRegExp(new RegExp()); //=> false
  19. */
  20. const isNotRegExp = complement(isRegExp);
  21. export default isNotRegExp;