title: Is it right to call a component function or its output in view form in yii2?
body: <p>I am stuck in a situation where I am trying to get the output of a component to be shown in the view form as a dropdown. I cannot use model to store the data from the component output and show it in the view. As that will result in a huge data storage and might slow the application processing. The only option left is to directly use this component output in view.</p>
  
  <p>Now, I am confused if I should call this output in controller and from controller I call the controller method in view similar to this: <a href="http://www.yiiframework.com/forum/index.php/topic/63169-way-to-call-controller-method-in-view-yii2/" rel="nofollow">http://www.yiiframework.com/forum/index.php/topic/63169-way-to-call-controller-method-in-view-yii2/</a> </p>
  
  <p>The other way is to use JS in frontend and use the component output shown there in the view. Not sure if this is a good way either. 
  What will be the right way to do this?</p>