xjsender / haoide

Stop upgrade, most of features were delivered in https://github.com/xjsender/haoide-vscode
MIT License
199 stars 46 forks source link

Autocomplete on lightning component using expression {!v.xxx} {!c.xxx} #170

Open Shababsoft opened 6 years ago

Shababsoft commented 6 years ago

Please can you also provide autocomplete on the lightning component (.cmp) as well for the following things, which will improve the development performance.

lushang commented 6 years ago

Planed doing this.

xjsender commented 6 years ago

@Shababsoft , Custom Label completion and attribute completion are working like what you said.

image image

xjsender commented 6 years ago

@Shababsoft , controller methods and helper methods completion is planning to deliver.

Shababsoft commented 6 years ago

@xjsender they work in controller and helper JavaScript files but not in HTML file (.cmp). Label completion work on $Label. but not if I put dot after "c" ($Label.c.), also we need to use $.get function to get a label in JS files. Please can you also double check that auto completion works in this scenario? $A.get ("$Label.c.xxxx");

xjsender commented 6 years ago

@Shababsoft , I think, every custom label in different managed package has it's namespace, it is difficult to identify that, I will try to use more reasonable way to match this.

label completion in html is not working now, it is bug, I think.

xjsender commented 6 years ago

@Shababsoft , actually, custom label completion works in cmp file, however, before it works, you must ensure you have already reloaded the project the custom label cache by Metadata > Reload Project Cache in the main menu.

image

image

image

Shababsoft commented 6 years ago

@xjsender I know custom label autocompete is working, I was only suggesting that completion also work when enter "." After "$Label.c". The autocompete does not work for attributes {!v.xxz} and controller {!c.xxx} in CMP file, I know you are aware of these things.

Thanks for working on this plugin.