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.

html and html like template ignore --single-quote

See original GitHub issue

Looks like --single-quote is being ignored for vue templates. Is this intentional?

Thanks

Prettier 1.16.4 Playground link

# Options (if any):
--single-quote --parser vue

Input:

<template>
	<div class='app'></div>
</template>

Output:

<template>
	<div class="app"></div>
</template>

Expected behavior: To leave the single quotes as is

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:4
  • Comments:26 (14 by maintainers)

github_iconTop GitHub Comments

4reactions
alexander-akaitcommented, Oct 2, 2019

We should respect user option

4reactions
alexander-akaitcommented, Sep 26, 2019

@theengineear agree @lydell right now we can use overrides for enforce single or double quotes based on path of files (https://github.com/prettier/prettier/blob/master/docs/configuration.md), but you can’t override option inside templates

Read more comments on GitHub >

github_iconTop Results From Across the Web

html - How can I escape a single quote? - Stack Overflow
The result for the above code is "hel" populated in the text box. How can I successfully escape the single quotes? html ·...
Read more >
Single Quote in HTML | PageDart
Can I use single quotes in HTML? ... Yes, you can! make sure to use either double quotes to wrap your values or...
Read more >
Strings - Manual - PHP
The simplest way to specify a string is to enclose it in single quotes (the character ' ). To specify a literal single...
Read more >
JavaScript Strings - W3Schools
The 6 escape characters above were originally designed to control typewriters, teletypes, and fax machines. They do not make any sense in HTML....
Read more >
Using single quotes to set an attribute in a template ... - HUGO
Declares a provided string as a "safe" HTML document to avoid escaping by Go templates. 2 Likes. SuperRoach August ...
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