Feature Implementation: Line Numbers
With those simple changes you add a new prop named "count_lines" default false, if parsed true this enable the css class "count-lines" into code mark, showing in this way the line's number at the left
The latest updates on your projects. Learn more about Vercel for Git ↗︎
| Name | Status | Preview | Updated |
|---|---|---|---|
| simple-code-editor | ✅ Ready (Inspect) | Visit Preview | Oct 18, 2022 at 9:46AM (UTC) |
@ErwinAI I applied some of the stuff we discussed up, anyway if you (or someone else) need use it "immediatly" you can use this code, directly into style scoped of the vue page where you use simple-code-editor, or just adding it in global way:
.code_editor:deep(pre>code>span){+
counter-increment: line;
}
.code_editor:deep(pre>code){
counter-reset: line;
}
.code_editor:deep(code>span:before){
content: counter(line);
position: absolute;
left: 1px;
font-size: 7px;
color: #777777;
padding-top: 4px;
}
^Bump
It has been a few weeks, I would like to use this feature
Is this going to be merged?
The new feature "line numbers" has been added