Google Chrome v147 introduced a newline regression

Open Beginner friendly
#135 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
Under an hour
Newbie friendliness
74/100
Issue type
Documentation
Clarity
Mostly clear
Activity status
Quiet
Tech stack
html
Domain
documentation

Research direction

Start by locating the CodeJar documentation that describes the editor container and compare its guidance with the reported Chrome v147 behavior for

 and  elements. Done when the documentation clearly states the supported container element and notes the behavior of other tags.

Written by the indexing model from the issue text.

Description

bug documentation

It seems like something changed in v147 of chrome. My app which was previously using codejar on a <pre> element saw newlines stop working. After investigation I found that <br> tags were being inserted when pressing return instead of newline characters: \n.

I discovered that I could resolve this issue by making the CodeJar container a <div> tag instead of a <pre> tag.

This was a surprise to me, so I am reporting it here so other developers can be made aware. Perhaps the CodeJar documentation should add a note that editors must be <div> tags, and that browser behavior with other tags is not supported.

Dominant language
TypeScript
Stars
2k
Forks
123
PR merge metrics
No merged PRs in 30d

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.

More from antonmedv/codejar

All issues in antonmedv/codejar

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.