How to implement a function when a component is created in Vue?
<p>According to the <a href="https://v2.vuejs.org/v2/guide/instance.html#Instance-Lifecycle-Hooks" rel="nofollow noreferrer">docs</a>, the constructor of the Vue object is managed like this.</p>
<pre><code>var vm = new Vue({
  created: function () { console.log(&quot;I'm created!&quot;); }
});
</code></pre>
<p>However, I can't figure out how to do the corresponding thing when a Vue component is created. I've tried the following but don't get any print to the console.</p>
<pre><code>export default {
  created: function() { console.log(&quot;Component created!&quot;); }
}
</code></pre>
<p>Is it possible to subscribe/listen to a component being rendered? I'd like to react to that event by downloading some data and putting it in the store, so that the table that the component carries will get its information to display.</p>