@yoo-digital/eslint-plugin-angular 3.0.2 → 3.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/rules/boolean-input.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -17,7 +17,7 @@ TypeScript rule that enforces `booleanAttribute` transform on boolean inputs
|
|
|
17
17
|
{
|
|
18
18
|
"files": ["**/*.ts"],
|
|
19
19
|
"rules": {
|
|
20
|
-
"@yoo-digital/eslint-plugin-angular/boolean-
|
|
20
|
+
"@yoo-digital/eslint-plugin-angular/boolean-input": "error"
|
|
21
21
|
}
|
|
22
22
|
}
|
|
23
23
|
```
|
|
@@ -146,7 +146,7 @@ exports.requireBooleanAttributeTransformRule = {
|
|
|
146
146
|
// Get the default value argument
|
|
147
147
|
const defaultValue = callExpr.arguments[0] ? sourceCode.getText(callExpr.arguments[0]) : 'false';
|
|
148
148
|
// Build the new call expression
|
|
149
|
-
const newCall = `input<boolean, BooleanInput>(${defaultValue}, {
|
|
149
|
+
const newCall = `input<boolean, BooleanInput>(${defaultValue}, { transform: booleanAttribute })`;
|
|
150
150
|
return fixer.replaceTextRange([callStart, callEnd], newCall);
|
|
151
151
|
},
|
|
152
152
|
});
|
package/package.json
CHANGED