uilint 0.2.117 → 0.2.118
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/dist/index.js +5 -4
- package/dist/index.js.map +1 -1
- package/package.json +5 -5
package/dist/index.js
CHANGED
|
@@ -2691,7 +2691,8 @@ async function buildCoverageData(appRoot) {
|
|
|
2691
2691
|
}
|
|
2692
2692
|
}
|
|
2693
2693
|
function handleRuleConfigSet(ws, ruleId, severity, options, requestId) {
|
|
2694
|
-
|
|
2694
|
+
const normalizedRuleId = ruleId.startsWith("uilint/") ? ruleId.slice("uilint/".length) : ruleId;
|
|
2695
|
+
logRuleConfigSet(normalizedRuleId, severity, !!options);
|
|
2695
2696
|
const configPath = findEslintConfigFile(serverAppRootForVision);
|
|
2696
2697
|
if (!configPath) {
|
|
2697
2698
|
const error = `No ESLint config file found in ${serverAppRootForVision}`;
|
|
@@ -2709,12 +2710,12 @@ function handleRuleConfigSet(ws, ruleId, severity, options, requestId) {
|
|
|
2709
2710
|
}
|
|
2710
2711
|
let result;
|
|
2711
2712
|
if (options && Object.keys(options).length > 0) {
|
|
2712
|
-
result = updateRuleConfigInConfig(configPath,
|
|
2713
|
+
result = updateRuleConfigInConfig(configPath, normalizedRuleId, severity, options);
|
|
2713
2714
|
} else {
|
|
2714
|
-
result = updateRuleSeverityInConfig(configPath,
|
|
2715
|
+
result = updateRuleSeverityInConfig(configPath, normalizedRuleId, severity);
|
|
2715
2716
|
}
|
|
2716
2717
|
if (result.success) {
|
|
2717
|
-
logServerInfo(`Updated uilint/${
|
|
2718
|
+
logServerInfo(`Updated uilint/${normalizedRuleId} -> ${severity}`);
|
|
2718
2719
|
eslintInstances.clear();
|
|
2719
2720
|
cache.clear();
|
|
2720
2721
|
updateCacheCount(0);
|