Skip to content
This repository was archived by the owner on Sep 18, 2023. It is now read-only.

Only allow string literal as tag name values. #33

Merged
merged 2 commits into from
Oct 11, 2021

Conversation

koddsson
Copy link
Contributor

@koddsson koddsson commented Oct 8, 2021

This is to prevent the rule from blowing up if there's no value property on the first argument such as if the argument is an expression.

const tagName = 'my-cool-element'

window.customElements.define(tagName, class extends HTMLElement)

@koddsson koddsson requested a review from keithamus October 8, 2021 14:03
Copy link
Contributor

@keithamus keithamus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 great!

@koddsson koddsson merged commit 39f6d67 into main Oct 11, 2021
@koddsson koddsson deleted the give-up-if-tag-name-doesnt-have-a-value branch October 11, 2021 12:22
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants