We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0fd28cc commit 05c9816Copy full SHA for 05c9816
package.json
@@ -1,6 +1,6 @@
1
{
2
"name": "@ant-design/cssinjs",
3
- "version": "2.0.0-alpha.1",
+ "version": "1.17.2",
4
"description": "Component level cssinjs resolution for antd",
5
"keywords": [
6
"react",
src/linters/NaNLinter.ts
@@ -0,0 +1,13 @@
+import type { Linter } from './interface';
+import { lintWarning } from './utils';
+
+const linter: Linter = (key, value, info) => {
+ if (
+ (typeof value === 'string' && /NaN/g.test(value)) ||
7
+ Number.isNaN(value)
8
+ ) {
9
+ lintWarning(`Unexpected 'NaN' in property '${key}: ${value}'.`, info);
10
+ }
11
+};
12
13
+export default linter;
0 commit comments