Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ember-template-lint

Package Overview
Dependencies
Maintainers
1
Versions
215
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ember-template-lint - npm Package Compare versions

Comparing version 0.5.16 to 0.5.17

17

CHANGELOG.md
Changelog
=========
## v0.5.17
- Fix issue with the `invalid-interactive` rule not honoring the documented `additonalInteractiveTags` option.
## v0.5.16
- Fix issue with `link-rel-noopener` rule when using properly with a listing (i.e. `rel="noopener noreferrer"`).
- Add `inline-link-to` rule to prevent usage of inline `{{link-to`.
- Add `style-concatenation` rule. This prevents the usage of `<div style="{{make-background url}}">` (quoted value with any dynamic segments) but allows
`<div style={{make-background url}}>`.
## v0.5.15
- Fix issue causing `<iframe>` to be detected as `{{#if`.
- Add `link-rel-noopener` rule. This rule requires that any `<a target="_blank">` have a `rel="noopener"`. This prevents the newly opened window from having access
to the opener (and helps prevent a number of phishing attacks).
## v0.5.14

@@ -5,0 +22,0 @@

13

lib/rules/lint-invalid-interactive.js

@@ -14,2 +14,12 @@ 'use strict';

InvalidInteractive.prototype.isCustomInteractiveElement = function(node) {
var additionalInteractiveTags = this.config.additionalInteractiveTags || [];
if (additionalInteractiveTags.indexOf(node.tag) > -1) {
return true;
} else {
return false;
}
};
InvalidInteractive.prototype.visitors = function() {

@@ -20,3 +30,4 @@ this._element = null;

enter: function(node) {
this._element = !isInteractiveElement(node) ? node : null;
var isInteractive = isInteractiveElement(node) || this.isCustomInteractiveElement(node);
this._element = !isInteractive ? node : null;
},

@@ -23,0 +34,0 @@

2

package.json
{
"name": "ember-template-lint",
"version": "0.5.16",
"version": "0.5.17",
"description": "Lint your templates.",

@@ -5,0 +5,0 @@ "scripts": {

@@ -13,3 +13,11 @@ 'use strict';

'<div role="button" {{action "foo"}}></div>',
'<li><button {{action "foo"}}></button></li>'
'<li><button {{action "foo"}}></button></li>',
{
config: { additionalInteractiveTags: ['div'] },
template: '<div {{action "foo"}}></div>'
},
{
config: { additionalInteractiveTags: ['div'] },
template: '<div onclick={{action "foo"}}></div>'
}
],

@@ -16,0 +24,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc