prettier / prettier/plugin-xml

Formatter fails on XML file with entity definitions

Open
#996 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
278
Forks
46
Avg merge
1m
Merged PRs (30d)
13

Description

Formatter fails with output:

Formatter failed, skipping: default prettier instance failed to format buffer: SyntaxError: unexpected character: ->[<- at offset: 70, skipped 1 characters. (3:26)

Input XML is attached. It is actually XSL but you can't attach that file type.

content.xml

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Download the attached content.xml and use it as the reproduction input for the XML formatter. Start by reproducing the reported failure around the entity definitions and XSL content, then verify that the same file formats successfully without the unexpected-character error.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.