The autocomplete works amazing. I am using schema.table: columns to provide the schema to autocomplete. But I have problem with icon here. All the icons for table or schema are taken as “type”. I need to differentiate between views,tables,functions under a schema using icon.
Any pointers on this please?
I tried passing tables to language.data.of → autocomplete → tables. But it adds to top schema. Is there some way to pass schema.view names (currently only string) as CompletionInfo so that I can change the type for view.
No. But if you pass a
schemas option you should be able to assign schemas another icon. The system has no concept of functions, at the moment.
Oops! So basically I need to re-implement schemaCompletionSource of lang-sql? Can I work on a PR if you’re willing to accept one? I can work on making schemaCompletionSource of lang-sql more customizable.
Are you willing to accept a PR if I work on some customisation of schemaCompletionSource?
I’d be willing to look at it, at least. Can’t guarantee anything about accepting.
OK fine. Anything expected to make it easy to accept? I will work accordingly.
I was mostly thinking of keeping the interface clean and understandable. But of course following the style of the rest of the code and having tests helps.
Can you please review my PR Allow adding any types of objects for autcompletion. by adityatoshniwal · Pull Request #15 · codemirror/lang-sql · GitHub?