question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[no-bare-strings] Automatically allow all HTML entities

See original GitHub issue

Things like × should be ignored by default by the no-bare-strings rule because they are built-in HTML constructs.

Forked from https://github.com/ember-template-lint/ember-template-lint/issues/662.

cc @rwjblue

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:1
  • Comments:10 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
rwjbluecommented, Mar 13, 2020

Ya, but we can work on that part regardless I think. A couple of ways:

  • expose the default array for importing, so folks can do [...defaults, 'thing-here']
  • add another option that is something like additionalAllowedStrings or something
1reaction
bmishcommented, Feb 22, 2020

I agree with having an option allowHTMLEntities which defaults to true to maintain the current behavior.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Using × gives a no-bare-strings warning #662 - GitHub
Can you create a new issue that suggests something like "automatically allow all HTML entities in no-bare-strings rule"?
Read more >
Fastest method to escape HTML tags as HTML entities?
Here's one way you can do this: var escape = document.createElement('textarea'); function escapeHTML(html) { escape.textContent = html; return escape.
Read more >
htmlentities - Manual - PHP
This function is identical to htmlspecialchars() in all ways, except with htmlentities(), all characters which have HTML character entity equivalents are ...
Read more >
&nbsp and HTML Space Challenges and Tricks | Mailtrap Blog
HTML entities are strings used to represent many reserved and invisible characters in ... We'll discuss them all in the following chapter.
Read more >
HTML Entities - W3Schools
Reserved characters in HTML must be replaced with character entities. ... Disadvantage of using an entity name: Browsers may not support all entity...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found