@locker/eslint-plugin-locker
Advanced tools
Comparing version 0.11.9 to 0.11.11
@@ -15,2 +15,3 @@ "use strict"; | ||
const null_document_location_1 = __importDefault(require("./rules/null-document-location")); | ||
const null_element_shadow_root_1 = __importDefault(require("./rules/null-element-shadow-root")); | ||
const null_shadow_root_host_1 = __importDefault(require("./rules/null-shadow-root-host")); | ||
@@ -29,2 +30,3 @@ const null_window_top_1 = __importDefault(require("./rules/null-window-top")); | ||
'null-document-location': null_document_location_1.default, | ||
'null-element-shadow-root': null_element_shadow_root_1.default, | ||
'null-shadow-root-host': null_shadow_root_host_1.default, | ||
@@ -31,0 +33,0 @@ 'null-window-top': null_window_top_1.default, |
@@ -15,3 +15,8 @@ "use strict"; | ||
rule: { | ||
message: `'shadowRoot.host' is 'null' in Lightning Locker.`, | ||
message(data) { | ||
const dotName = data.pattern.slice(2); | ||
const nodeText = data.context.getSourceCode().getText(data.node); | ||
const matchedText = nodeText.slice(0, nodeText.indexOf(dotName) + dotName.length); | ||
return `'${matchedText}' is 'null' in Lightning Locker.`; | ||
}, | ||
search: ['*.host'], | ||
@@ -18,0 +23,0 @@ }, |
@@ -10,6 +10,7 @@ "use strict"; | ||
const { repository, version } = JSON.parse(fs_1.default.readFileSync(pkgJSONPath, 'utf8')); | ||
const url = repository.url.replace(/\.git$/, ''); | ||
function docURL(ruleName) { | ||
return `${repository.url}/blob/v${version}/packages/%40locker/eslint-plugin-locker/docs/rules/${ruleName}.md`; | ||
return `${url}/blob/v${version}/packages/%40locker/eslint-plugin-locker/docs/rules/${ruleName}.md`; | ||
} | ||
exports.docURL = docURL; | ||
//# sourceMappingURL=util.js.map |
{ | ||
"name": "@locker/eslint-plugin-locker", | ||
"version": "0.11.9", | ||
"version": "0.11.11", | ||
"license": "MIT", | ||
@@ -22,3 +22,3 @@ "description": "Locker Next eslint rules", | ||
"dependencies": { | ||
"@locker/eslint-rule-maker": "0.11.9" | ||
"@locker/eslint-rule-maker": "0.11.11" | ||
}, | ||
@@ -39,3 +39,3 @@ "devDependencies": { | ||
], | ||
"gitHead": "7fd681f08f87206dfb944c258dac4eb12a98a6eb" | ||
"gitHead": "edea12f8387424f6b8f26cb9972db921e19c06ee" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
28616
33
362
1
+ Added@locker/ast-lib-maker@0.11.11(transitive)
+ Added@locker/eslint-rule-maker@0.11.11(transitive)
+ Added@locker/shared@0.11.11(transitive)
- Removed@locker/ast-lib-maker@0.11.9(transitive)
- Removed@locker/eslint-rule-maker@0.11.9(transitive)
- Removed@locker/shared@0.11.9(transitive)