language-tools icon indicating copy to clipboard operation
language-tools copied to clipboard

Provide Symbols to VSCode

Open iddan opened this issue 4 years ago • 5 comments
trafficstars

Problem

When editing Prisma Schema in VSCode I can't search for symbols as the language server does not provide them.

Suggested solution

Provide VSCode symbol information about the models, fields, and generators in the file.

Additional context

https://microsoft.github.io/language-server-protocol/specifications/specification-current/#workspace_symbol

iddan avatar Mar 25 '21 09:03 iddan

This would be a huge help in navigating a schema file.

dariusj18 avatar Nov 03 '21 14:11 dariusj18

@dariusj18 What are your expectations here? Which symbols do you want to see?

Jolg42 avatar Nov 03 '21 16:11 Jolg42

Note: this video shows how it would work for example https://www.youtube.com/watch?v=SyZXIuGfUFI

Jolg42 avatar Nov 03 '21 16:11 Jolg42

At the very least each model/enum showing up as a symbol would be useful. If I could hit Ctrl+Shift+O and start typing a model name to navigate to it quickly, it would be a much cleaner thing than hitting Ctrl+F and typing "model MODELNAME"

Plus the Outline view would become useful.

dariusj18 avatar Nov 03 '21 17:11 dariusj18

Need more attention for this feature, navigating in a large schema is painful!

KhanhHH avatar Aug 11 '22 05:08 KhanhHH