Functionality like $(document).ready( with Vue.js

I wrote a small code with Laravel, Vue and JQuery, which works fine. Now I want to remove JQuery and run all with Vue and Axios.

Here’s my template:

 <ul id="product_list" class="vue-list-wrapper list-wrapper" data-rest="{{ route('rest_get_products', ["id"=>$product_type_id]) }}" data-pagination="0">
    <li v-for="item in items">
        <div class="item-name item-section">@{{ }}</div>
        ...bla bla...

Following code actually works and I can render what I get from AJAX. I know how to apply Axios, no problem. The point I’m confused: How can I ensure $(document).ready( functionality with Vue?

"use strict";

function init_vue_list(){

    var vue_list_handler = new Vue({
        el: '.vue-list-wrapper',
        data: {
            items: []
        mounted: function (event) {
            var self = this;
            var ajax_url = this.$el.getAttribute('data-rest');

            $.ajax({ // No problem to convert this to Axios.
                url: ajax_url,
                method: 'GET',
                success: function (data) {
                    self.items = data;
                error: function (error) {



$(document).ready( // I'm confused how I can replace this with Vue.
        if($('.vue-list-wrapper').length > 0) {

})(document, $);

158 thoughts on “Functionality like $(document).ready( with Vue.js”

  1. Pingback: strip sex games
  2. Old people’s parting words to young people are not only a waste of time, but also impudence .
    Each generation considers itself to be completely different from the previous one, although in the end it turns out to be almost the same.
    If I look back on my life, I believe that I was constantly wrong.
    The same will happen to you when you grow up. Enjoy life and make mistakes. This is life.
    Don’t think you can be perfect – that’s not possible.
    Temper yourself, your will, so that when the test comes, you will find the strength in yourself to accept it as a true man.
    Do not allow yourself to be fooled by obvious facts and loud phrases.
    Travel, explore the world, meet people, work on something that excites you, fall in love, be daring but do it with passion.
    The most important thing is to live your life with taste.
    Maybe we have more than one life ahead of us. But to get them, you need to use this life to the fullest. Take as much from life as you can.
    Fear colorless fate.

  3. Unions and shipping bodies urge safe passage from Black Sea and Sea of Azov after missile strikes and at least one death reported plsHelpUkraine03202216

  4. Привет друзья!
    Более подробная информация размещена
    Предлагаем Вашему вниманию изделия из стекла для дома и офиса.Наша организация ООО «СТЕКЛОЭЛИТ» работает 10 лет на рынке этой продукции в Беларуси.Офис сегодня – это не пыльная комната в панельном здании, а лицо компании, его визитная карточка. Во многом это определяет интерьер, но также огромное значение имеют дверные конструкции и стеклянные перегородки в офисе. Появившись в качестве перегородок достаточно давно, стеклянные стены использовались чаще всего просто в качестве разделителя помещения, и только недавно они вошли в список интерьерных изюминок. В своих конструкциях мы используем стекло от лучшего мирового производителя листового стекла AGC GLASS EUROPE.

  5. Автоновости на всё о машинах и авторынке — Интересные новости о выпусках, разработках, происшествий об автомобилей – Автоновости на всё о машинах и авторынке — Интересные новости о выпусках, разработках, происшествий об автомобилей!..

  6. Howdy! This post couldn’t be written any better! Reading this
    post reminds me of my old room mate! He always kept talking about this.

    I will forward this page to him. Pretty sure he will have
    a good read. Thanks for sharing!

  7. Its such as you learn my mind! You seem to understand a
    lot approximately this, such as you wrote the e-book in it or something.

    I feel that you could do with some percent to
    pressure the message house a little bit, but instead of that, that is fantastic
    blog. A great read. I’ll certainly be back.

  8. When I initially left a comment I appear to have clicked the -Notify me when new comments
    are added- checkbox and now every time a comment is added I receive four emails
    with the exact same comment. Is there an easy method you are
    able to remove me from that service? Many thanks!

  9. I’m not sure where you are getting your information, however good topic.
    I needs to spend some time learning more
    or working out more. Thank you for magnificent info I used to be looking for this information for
    my mission.

  10. На официальном сайте Франк выдается
    бездепозитный приз в виде фриспинов.

    Фриспины активируются в популярных автоматах.
    Правила получения приза детально опубликованы на сайте – в разделе «Акции».
    Получить бездеп вполне возможно по
    акционному коду, вписав его в
    специальное окно. Кроме бездепозитного подарка, новичкам выдается бонус на первый депозит.
    Помимо денег, за внесение депозитов посетителям
    могут предоставляться фриспины.

  11. Please let me know if you’re looking for a article author for your weblog.

    You have some really good posts and I feel I would be a good asset.
    If you ever want to take some of the load off, I’d love to write some articles for
    your blog in exchange for a link back to mine. Please blast me an e-mail if interested.

  12. Hey! I could have sworn I’ve been to this site before but after browsing through some of the post I realized it’s new to me.

    Anyways, I’m definitely happy I found it and I’ll be book-marking
    and checking back frequently!

  13. I don’t even know the way I stopped up here, however I believed this post
    used to be good. I don’t recognise who you might be but
    definitely you are going to a famous blogger in case you are not already.

  14. Very great post. I just stumbled upon your weblog
    and wanted to mention that I’ve really loved surfing
    around your weblog posts. In any case I will be subscribing
    for your rss feed and I’m hoping you write again soon!

  15. That is really interesting, You are a very professional blogger.

    I have joined your feed and look forward to looking for more of your wonderful
    post. Additionally, I have shared your site in my
    social networks