function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion

Accessing apex list string property in lightning attribute component

I am able to fetch the apex list of string property in my lightning component through my visualforce page but unable to get values in desired way. 
here is my code
apex code snippet as 

public class linkforLightning{
    public string links {
    public string getlink(){
        links = 'apex/TestVFWITHLIGHTNING';
        return links;
    public list<string> getlistOfString(){
        list<String> listOfstring = new List<String>();
        string s = 'abc';
        string s2 = 'XYZ';
        return listOfstring;

Component code snippet
<aura:attribute name="contactLevel" type="set" default="test" />
    <aura:handler name="init" value="{!this}" action="{!c.onSelectChange}"/>
    <ui:inputSelect aura:id="levels" label="Contact Levels" change="{!c.onSelectChange}">
        <aura:iteration items="{!v.contactLevel}" var="level">
             <ui:inputSelectOption text="{!level}" label="{!level}"/>

Visualforce code snippet :

$Lightning.use("AnkushTest:onSelectChange", function() {

Output is below :-

[" a" b" c" ," " X" Y" Z" ]" [

I want the out put as 
abc, xyz
I need to show it in a picklist field