-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Eslintify panel #35
Eslintify panel #35
Changes from 4 commits
af0fe51
d2bbdd5
9a3be0c
2e5a5ca
d8f74ec
478a1c4
6a86b03
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
/* global global */ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Shouldn't this be |
||
/** | ||
* Node.js polyfill for rendering Panel components without a browser. | ||
* Makes the following objects globally available: | ||
|
@@ -27,7 +28,7 @@ import requestAnimationFrame from 'raf'; | |
global.requestAnimationFrame = global.requestAnimationFrame || requestAnimationFrame; | ||
|
||
// patch DOM insertion functions to call connectedCallback on Custom Elements | ||
['appendChild', 'insertBefore', 'replaceChild'].forEach(funcName => { | ||
[`appendChild`, `insertBefore`, `replaceChild`].forEach(funcName => { | ||
const origFunc = Element.prototype[funcName]; | ||
Element.prototype[funcName] = function() { | ||
const child = origFunc.apply(this, arguments); | ||
|
@@ -76,7 +77,7 @@ Document.prototype.createElement = function(tagName) { | |
el = originalCreateElement(...arguments); | ||
} | ||
return el; | ||
} | ||
}; | ||
|
||
global.customElements = global.customElements || { | ||
define(tagName, proto) { | ||
|
@@ -86,5 +87,5 @@ global.customElements = global.customElements || { | |
} else { | ||
registeredElements[tagName] = proto; | ||
} | ||
} | ||
}, | ||
}; |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,11 @@ | ||
import { Component, h } from '../../lib'; | ||
import {Component, h} from '../../lib'; | ||
|
||
export class AttrReflectionApp extends Component { | ||
get config() { | ||
return { | ||
template: state => h('div', {class: {'attr-app': true}}, [ | ||
h('p', `Value of attribute wombats: ${this.getAttribute('wombats')}`), | ||
// eslint-disable-next-line no-unused-vars | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's just a test fixture, might as well make it conform with |
||
template: state => h(`div`, {class: {'attr-app': true}}, [ | ||
h(`p`, `Value of attribute wombats: ${this.getAttribute(`wombats`)}`), | ||
]), | ||
}; | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yikes! dead weight