Flag of Ukraine
SymfonyCasts stands united with the people of Ukraine
Next Chapter

Challenge #1 of 3


Q: 

Pizza time! Check out the following component where we need to hide or show a "Loading" message depending on a loading state.

<template>
    <span>Loading...</span>

    <h1>Pizza Menu</h1>

    <pizza-menu-list />
</template>

<script>
import PizzaMenuList from '@/components/pizza-menu-list';

export default {
    name: 'MainComponent',
    components: {
        PizzaMenuList
    },
    data() {
        return {
            loading: true,
        };
    },
};
</script>

What is the best way to hide and show the "Loading" <span>?

userVoice