Closed HeroicEric closed 11 months ago
Components are not formatted correctly when <template> contains unicode characters such as β or Β© rather than ✓ or ©.
<template>
β
Β©
✓
©
Failing test added in https://github.com/gitKrystan/prettier-plugin-ember-template-tag/pull/221
import Component from '@glimmer/component'; export interface Signature { Element: HTMLElement, Args: {} Yields: [] } /** It's a component */ class MyComponent extends Component<Signature> { <template> β </template> } function hello() { return 'Hello'; } function world() { return 'World'; }
import Component from "@glimmer/component"; export interface Signature { Element: HTMLElement; Args: {}; Yields: []; } /** It's a component */ class MyComponent extends Component<Signature> { <template>β</template> } function hello() { return "Hello"; } function world() { return "World"; }
Note: The newlines are removed between the helper functions.
Replacing the direct symbols with the HTML entity codes like ✓ fixes the formatting issue (and is preferred anyway)
Thanks for the report! This sounds like a duplicate of https://github.com/gitKrystan/prettier-plugin-ember-template-tag/issues/191
π Describe the Bug
Components are not formatted correctly when
<template>
contains unicode characters such asβ
orΒ©
rather than✓
or©
.π¬ Minimal Reproduction
Failing test added in https://github.com/gitKrystan/prettier-plugin-ember-template-tag/pull/221
π Actual Behavior
Note: The newlines are removed between the helper functions.
π€ Expected Behavior
π Environment
β Additional Context
Replacing the direct symbols with the HTML entity codes like
✓
fixes the formatting issue (and is preferred anyway)