is-reg-exp.js 370 B

123456789101112
  1. 'use strict';
  2. module.exports = function (t, a) {
  3. a(t('arar'), false, "String");
  4. a(t(12), false, "Number");
  5. a(t(true), false, "Boolean");
  6. a(t(new Date()), false, "Date");
  7. a(t(new String('raz')), false, "String object");
  8. a(t({}), false, "Plain object");
  9. a(t(/a/), true, "Regular expression");
  10. a(t(new RegExp('a')), true, "Regular expression via constructor");
  11. };