V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
fang2hou
V2EX  ›  Neovim

go-impl.nvim - 一个基于 impl 的 Go 接口实现插件

  •  
  •   fang2hou · Jan 4, 2025 · 1620 views
    This topic created in 477 days ago, the information mentioned may be changed or developed.

    本来打算年前努力写完的,但是漫威争锋太好玩了🐶。在这个新年假期快结束的时点,终于完成了我的第一款 Neovim 插件,希望能为各位 Go 语言开发者提升工作效率!

    主要特性

    • 完全异步:所有操作均无阻塞,体验流畅。
    • Receiver 智能推断:根据光标位置自动寻找最近的结构体来推断 Receiver ,减少手动操作。
    • Treesitter 验证:在执行 impl 前确保 Receiver 有效,避免错误。
    • 快速接口选择:集成 fzf-lua,支持非常高速的搜索,预览和选择。
    • 泛型参数支持:支持指定泛型参数类型,输入时提供高亮提醒和接口声明。

    GitHub (附演示动画)

    👉 https://github.com/fang2hou/go-impl.nvim

    1 replies    2025-06-15 18:43:22 +08:00
    Vintingb
        1
    Vintingb  
       Jun 15, 2025 via iPhone
    这个不错,nvim 一直没找到类似的插件
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   947 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 29ms · UTC 22:40 · PVG 06:40 · LAX 15:40 · JFK 18:40
    ♥ Do have faith in what you're doing.