PrismJS / PrismJS/prism

Indentation when line of code wraps.

Open
#2,202 3 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement help wanted plugins
Dominant language
JavaScript
Stars
13k
Forks
1.4k
Avg merge
15h 36m
Merged PRs (30d)
3

Description

Motivation
There is no easy way to have indented line breaks.

Description
I do not want to have to horizontally scroll when my code is too long and want to wrap it to the next line. However when I do this like https://github.com/PrismJS/prism/issues/1237 the line wraps over to the next line without any indents. I want to wrap the line over with indenting like in many code editors (like vs code press Alt + Z https://stackoverflow.com/questions/31025502/how-can-i-switch-word-wrap-on-and-off-in-visual-studio-code) .

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

The issue points to Prism issue 1237 as the closest prior example; read it first and reproduce the unindented wrap with a long code line. Done means wrapped lines visibly retain the requested indentation without horizontal scrolling, with the behavior checked against existing Prism highlighting output.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.