uiwjs / uiwjs/react-codemirror
Highlight specific text inside a code
Open
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 2.3k
- Forks
- 161
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
I am using react-codemirror to show case php code in my application.
Is it possible to highlight specific text in the code ?
Example:
In the below code, is it possible to highlight echo with a yellow background
<?php
$colors = array("red", "green", "blue", "yellow");
foreach ($colors as $value) {
echo "value";
}
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the react-codemirror highlighting entry points and existing examples for applying a background to selected text. Confirm whether the requested PHP example can highlight only the word "echo" in yellow; done means a documented or tested way to reproduce that result.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100