Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: :n file suffix doesn't scroll if browser (firefox) wasn't already open #193

Closed
tuurep opened this issue Dec 4, 2024 · 3 comments · Fixed by #196
Closed

Bug: :n file suffix doesn't scroll if browser (firefox) wasn't already open #193

tuurep opened this issue Dec 4, 2024 · 3 comments · Fixed by #196
Labels
type:bug Something isn't working

Comments

@tuurep
Copy link
Collaborator

tuurep commented Dec 4, 2024

Description

When using the :n CLI file suffix to scroll to a certain line, if firefox wasn't already open, the viewer doesn't scroll.

(viv launches firefox).

Practical use case where this matters: using the vim-plugin, you want to render the markdown on the line you're currently looking at in Vim.

To Reproduce

  1. Have firefox set as default browser.
  2. With no browser running:
  • $ viv README.md:90 (example: this repo's README.md)
  1. Doesn't scroll after opening the browser and viewer (opens at the top)

Context

Arch Linux

vivify-server v0.6.3.r0.g5d07d16-1-aur

vivify-git (AUR)

@tuurep tuurep added the type:bug Something isn't working label Dec 4, 2024
@tuurep
Copy link
Collaborator Author

tuurep commented Dec 4, 2024

Please comment if this happens on browsers other than firefox, too

@jannis-baum
Copy link
Owner

I finally got to check this and can confirm that it doesn't work on my Firefox either. However on both Safari and Chromium it scrolls as it should.

@tuurep
Copy link
Collaborator Author

tuurep commented Jan 7, 2025

Note: we couldn't completely fix this on firefox (especially Linux), but the PR makes it happen only very infrequently (~1/20 of launches) in a lot of cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants