mProjectsCode / mProjectsCode/obsidian-shiki-plugin

Highlighting stops when rumdl (plugin) does format on save on CTRL+S.

Open
#81 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
TypeScript
Stars
238
Forks
25
PR merge metrics
No merged PRs in 30d

Description

  • The Plugin is up to date
  • Obsidian is up to date

Describe the bug

[!NOTE]
I don't know if this is a bug in obsidian-shiki-plugin or Obsidian. It's likely not in obsidian-rumdl?

Just wanted to create an issue with info about it, and hopefully someone can figure out where and why it happens.

I use rumdl for linting and format on save:

When I do changes in a note where CTRL+S triggers rumdl format/fix, and rumdl does changes, this highlighter stops highlighting code.

To Reproduce

  1. Install this plugin and rumdl.
  2. Enable format on save with the rumdl plugin.
  3. Create a note with a code block, and add two-three consecutive lines somewhere outside the code block.
  4. Save file CTRL+S, which triggers rumdl, which will remove consecutive blank lines.
  5. See Shiki highligter stopped highlighting code.

Expected behavior

Highlighting of code should not stop.

Screenshots

https://github.com/user-attachments/assets/363f53e0-02e0-4f24-8c75-22af1d840700

Occurs on

  • Windows
  • macOS
  • Linux
  • Android
  • iOS

Plugin version

v0.7.7

Additional context
Add any other context about the problem here.

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

No source file or test is named. First reproduce the issue with Obsidian, obsidian-shiki-plugin v0.7.7, and rumdl format-on-save, then inspect the plugin's highlighting update path around an externally modified note. Done means code highlighting remains active after CTRL+S causes rumdl to remove consecutive blank lines.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
desktop-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.