kangax / kangax/html-minifier

HTML Parser error

Open
#1,160 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
5k
Forks
577
PR merge metrics
No merged PRs in 30d

Description

Error: Parse Error:

  <html lang="en">
    <head>
      <meta charset="UTF-8" />
      <meta name="viewport" content="width=device-width, initial-scale=1.0" />
      <title>Academic Counseling Chatbot</title>
    </head>
    <body>
      <noscript>You need to enable JavaScript to run this app.</noscript>
      <div id="root"></div>
    </body>
  </html>```
  
  - htmlparser.js:255 HTMLParser.parse
    [chatbot]/[html-minifier-terser]/src/htmlparser.js:255:15
  
  - task_queues:105 process.processTicksAndRejections
    node:internal/process/task_queues:105:5
  
  - htmlminifier.js:1282 async minify
    [chatbot]/[html-minifier-terser]/src/htmlminifier.js:1282:3
  
  - htmlminifier.js:1365 async exports.minify
    [chatbot]/[html-minifier-terser]/src/htmlminifier.js:1365:16

Why is this occuring, even when the html syntax is correct

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

Start at htmlparser.js:255 in html-minifier-terser and trace the async minify call through htmlminifier.js:1282 and 1365. Reproduce the parse error with the supplied HTML, then determine and document the condition that causes valid HTML to be rejected, with a regression test if the repository provides a relevant test location.

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
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.