Commit graph

78 commits

Author SHA1 Message Date
Sindre Sorhus
1f2440ae0d Add is.optional and assert.optional
Fixes #111
2025-09-13 15:48:57 +07:00
Sindre Sorhus
0ff273fee8 Require Node.js 18 2024-07-10 15:41:12 +02:00
Sindre Sorhus
f7148e19dc Meta tweaks 2024-04-29 01:32:06 +07:00
Martin Eneqvist
f2e5834421
Support custom assertion messages (#204)
Co-authored-by: Sindre Sorhus <sindresorhus@gmail.com>
2024-04-23 12:58:28 +07:00
Sindre Sorhus
07ea404e86 Meta tweaks 2024-02-29 14:26:01 +07:00
Martin Eneqvist
e9418fe1b9
Add .validDate() (#203) 2024-02-29 14:23:30 +07:00
patrik csak
0e687a23a8
Fix readme headings (#202) 2024-01-06 14:30:28 +07:00
Bjorn Stromberg
bcec30d735
Rename is.domElement() to is.htmlElement() (#196) 2023-08-10 16:06:46 +02:00
Bjorn Stromberg
ee79af32b6
Update class method description (#195)
Co-authored-by: Harminder Virk <virk.officials@gmail.com>
2023-08-10 16:05:22 +02:00
Bjorn Stromberg
5044c91273
Implement named exports (#191) 2023-08-07 02:50:03 +02:00
Tal Michel
3868f47783
Add .tupleLike() (#189)
Co-authored-by: Sindre Sorhus <sindresorhus@gmail.com>
2023-07-23 14:35:23 +02:00
Eugene
1284da085f
Add is.positiveNumber and is.negativeNumber (#184) 2023-07-15 00:26:30 +02:00
Eric(书生)
e503a9ec49
Add .weakRef() (#165)
Co-authored-by: Sindre Sorhus <sindresorhus@gmail.com>
2022-06-13 14:05:26 +07:00
Sindre Sorhus
d6fc1ce0fe Require Node.js 14, TS 4.7, and move to ESM (#167) 2022-06-11 17:44:43 +07:00
Eric(书生)
5b7ea154e6
Add .isBlob() (#162)
Co-authored-by: Sindre Sorhus <sindresorhus@gmail.com>
2022-02-27 14:16:25 +07:00
Sindre Sorhus
6cbefb9af7 Meta tweaks 2022-02-25 16:19:29 +07:00
Ivan Katliarchuk
23cf074a73
Add .nonEmptyStringAndNotWhitespace() (#161)
Co-authored-by: Sindre Sorhus <sindresorhus@gmail.com>
2022-02-25 16:10:57 +07:00
Sindre Sorhus
04ccf21dba Document TypeScript naming limitation
Fixes #157
2022-02-01 11:37:28 +07:00
Pedro Augusto de Paula Barbosa
73daee6648
Improve .enumCase doc formatting in readme (#154) 2022-01-18 11:48:03 +07:00
Olivier Beaulieu
a5b4017d5e
Add is.enumCase and assert.enumCase (#150)
Co-authored-by: Sindre Sorhus <sindresorhus@gmail.com>
2022-01-17 12:55:40 +07:00
Sindre Sorhus
a82aeeaa5e Add FAQ about instanceof 2021-10-31 12:34:45 +07:00
Kayson Wu
a8de3d6f34
Add is.formData and is.urlSearchParams (#139) 2021-09-13 21:25:44 +07:00
PopGoesTheWza
d2f98e472d
Add is.propertyKey (#138)
Co-authored-by: Sindre Sorhus <sindresorhus@gmail.com>
Co-authored-by: Giora Guttsait <giora111@gmail.com>
2021-09-10 15:26:13 +07:00
Richie Bendall
da6bb531af
Move to GitHub Actions (#129) 2021-01-02 11:25:04 +07:00
Arnovsky
3f93bf200d
Add is.array overload that supports asserting array items (#119)
Co-authored-by: Pedro Augusto de Paula Barbosa <papb1996@gmail.com>
Co-authored-by: Giora Guttsait <giora111@gmail.com>
Co-authored-by: Sindre Sorhus <sindresorhus@gmail.com>
2020-07-25 09:11:59 +02:00
Bjorn Stromberg
a96abee1a3
Use shields.io for number of downloads per week (#118) 2020-06-27 19:13:23 +08:00
Dave Cohen
d1929ad47c
Add support for multiple predicates to is.any (#104) 2020-02-16 20:06:19 -05:00
Sindre Sorhus
f97029fd73 Minor readme tweaks 2020-01-30 00:51:52 +07:00
Sindre Sorhus
5d0ccec21c Meta tweaks 2020-01-30 00:45:06 +07:00
Forresst
446a7a081e
Add .asyncGenerator and .asyncGeneratorFunction detection (#100) 2020-01-30 00:35:58 +07:00
Joel Purra
d28c86ee27
Propagate generic types where possible (#103) 2020-01-29 23:22:35 +07:00
Sindre Sorhus
11003b925e Meta tweaks 2020-01-22 19:17:43 +07:00
Joel Purra
0c3f110386 Add assertion type guards (#97) 2020-01-22 18:08:35 +07:00
Blaine Bublitz
0cc82c583e Fix a readme link (#96) 2019-10-31 11:20:49 +07:00
Sindre Sorhus
8ff75abfff Tidelift tasks 2019-10-30 20:01:23 +07:00
Sindre Sorhus
0f9b8479e9 Tidelift tasks 2019-09-10 12:46:18 +07:00
Sindre Sorhus
4f4820ef2f Meta tweaks 2019-06-30 15:18:24 +07:00
Kai Niedziela
f04dffa575 Make is.number(NaN) return false (#90)
Co-authored-by: Sindre Sorhus <sindresorhus@gmail.com>
2019-06-30 15:09:07 +07:00
Sindre Sorhus
04cd282265 Fix the capitalization of is.bigInt64Array and is.bigUint64Array 2019-05-13 11:04:48 +07:00
Sindre Sorhus
79144f9542 Readme tweaks 2019-02-12 14:40:44 +07:00
Scottie Enriquez
2502442404 Rename .odd() to .oddInteger() and .even() to .evenInteger() for clarity (#77) 2019-02-04 02:38:38 +07:00
Sindre Sorhus
0e1cce5d45
Fix readme typo 2019-01-11 16:34:29 +07:00
Itai Steinherz
4d0120adb7 Fix is.urlString documentation (#76) 2018-12-13 22:38:35 +01:00
Itai Steinherz
566f363632 Add is.urlString (#73) 2018-12-13 16:52:21 +01:00
jokebookservice1
b8a9fb457c Minor documentational correction (#69) 2018-11-02 23:04:44 +07:00
Sindre Sorhus
69bbf2d4be Readme improvements 2018-11-02 19:07:38 +07:00
Itai Steinherz
7317226c80 Add is.numericString() (#67) 2018-11-01 18:21:49 +07:00
Sindre Sorhus
45c976071a Don't import util
We don't really need its full power. Not worth the bloat.
2018-09-28 13:32:55 +07:00
Arfat Salman
6e07df5896 Add emptiness methods (#61)
Fix #53
2018-09-28 13:24:35 +07:00
Artur Androsovych
3bdaf21475 Add is.urlInstance (#60) 2018-07-10 16:04:20 +07:00