<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>结构渲染</title>
</head>
<body>
    <div id="app">
        <div v-show="loginBy">
            <label>手机号登录</label>
            <input type="text" placeholder="输入手机号" key="mobile" value="1">
        </div>
        <div v-show="!loginBy">
            <label for="">邮箱登录</label>
            <input type="text" placeholder="输入邮箱" key="email" value="2">
        </div>
        <button v-on:click="loginBy= !loginBy">更换登录方式</button>
    </div>

    <script src="../js/vue.js"></script>

    <script>
        let vm = new Vue({
            el:'#app',
            data:{
                loginBy: true
            }
        });
    </script>
</body>
</html>