|
1 | 1 | # clapi.nvim |
2 | 2 |
|
3 | | -The [telescope.nvim](https://github.com/nvim-telescope/telescope.nvim) pickers to show document symbols don't include the items' visibility modifiers. This extension provides a picker including them, so you can display and navigate the class/module interface easily. |
| 3 | +This is a Neovim plugin that analyzes the entire class/module hierarchy, including the document symbols of parent classes, traits, interfaces, and other inherited elements, giving you a complete view of the API surface. |
| 4 | + |
| 5 | +**Why this project?** |
| 6 | +The [telescope.nvim](https://github.com/nvim-telescope/telescope.nvim) pickers to show document symbols don't include the items' visibility modifiers. This is a fundamental feature to reason about the interfaces you're exposing in order to design a well-architected codebase. Without visibility information, it's difficult to: |
| 7 | + |
| 8 | +- Understand which methods and properties are part of the public API |
| 9 | +- Identify protected members available to subclasses |
| 10 | +- Distinguish between implementation details and interface contracts |
| 11 | + |
| 12 | +clapi.nvim solves this by providing a complete picture of your class interfaces, making proper API design and navigation significantly easier. |
| 13 | + |
| 14 | +--- |
4 | 15 |
|
5 | | -The plugin analyzes the entire class/module hierarchy, including parent classes, traits, interfaces, and other inherited elements, giving you a complete view of the API surface. |
6 | 16 |  |
7 | 17 |
|
8 | 18 | ## Supported Languages |
@@ -102,15 +112,18 @@ require('telescope').setup { |
102 | 112 | ## Troubleshooting |
103 | 113 |
|
104 | 114 | **Q: No symbols are displayed for my file** |
105 | | -A: Make sure you have the appropriate language parser installed for treesitter: |
| 115 | +- A: clapi needs treesitter in order to work. The language parsers should have been installed automatically, but make sure they are available: |
106 | 116 | ```vim |
107 | 117 | :TSInstall php |
108 | 118 | :TSInstall java |
109 | 119 | ``` |
110 | 120 |
|
111 | 121 | **Q: Some inherited members are missing** |
112 | | -A: The plugin requires proper parsing of the inheritance hierarchy. Ensure your project structure allows the plugin to find parent classes and interfaces. |
113 | | -A: Check that you have an LSP installed and attached to the current buffer. It may take a few seconds since you open the file. |
| 122 | +- A: Check that you have an LSP installed and attached to the current buffer. It may take a few seconds since you open the file. |
| 123 | +- A: The plugin requires proper parsing of the inheritance hierarchy. Ensure your project structure allows the LSP to find parent classes and interfaces. |
| 124 | + |
| 125 | +**Q: Where does the "clapi" name come from** |
| 126 | +- A: clapi it's a silly acronym coming from Class API, in case the mnemotechnics comes useful for you :) |
114 | 127 |
|
115 | 128 | ## Contributing |
116 | 129 |
|
|
0 commit comments