RicardoRamirezR / blade-nav.nvim

Navigating Blade views within Laravel projects
MIT License
37 stars 4 forks source link

`gf` mapping breaks navigating to file under cursor #21

Closed calebdw closed 1 month ago

calebdw commented 1 month ago

Hello!

Pressing gf to navigate to the file under my cursor no longer works, and I noticed this remaps it. I'm fine with that in blade files because there's not really file paths in blade, but I can't have it replace that functionality globally.

Thanks!

RicardoRamirezR commented 1 month ago

Hi @calebdw,

In a composer.json:

"autoload-dev": {
    "files": [
        "tests/utilities/functions.php"
    ],
    "psr-4": {
        "Tests\\": "tests/"
    }
},

I do gf over the functions.php the file is opened, then open any blade file, then back to composer.json then gf again and still works.

I have gf mapped to :edit <cfile>, btw

Can you give an example to reproduce it, please

Edit: I do gf over the functions.php the file is opened, then open any blade file, copy the tests/utilities/functions.php line in to it, gf over it, it opens the tests/utilities/functions.php file, then back to composer.json then gf again and still works.

RicardoRamirezR commented 1 month ago

I made it less intrusive, but still should work in blade and php files. Let me know.

calebdw commented 1 month ago

I think that worked, thanks!

calebdw commented 1 month ago

Completed in https://github.com/RicardoRamirezR/blade-nav.nvim/commit/56c1538a093688a5a24ade3c1bcf7b0e3a15eee9