yantianqi
V2EX  ›  问与答

vue 声明周期钩子函数 mounted,页面渲染了吗

  •  
  •   yantianqi · May 31, 2017 · 2322 views
    This topic created in 3291 days ago, the information mentioned may be changed or developed.

    如果在 mounted 中运行一个 alert,弹窗前页面没有数据,弹窗后页面有了数据
    mounted 是页面什么时候?

    2 replies    2017-05-31 22:56:03 +08:00
    SourceMan
        1
    SourceMan  
       May 31, 2017 via iPhone
    不是今天有人问了吗?
    迁移指南有说到这事
    用 vm.$nextTick 确保下
    airyland
        2
    airyland  
       May 31, 2017 via iPhone
    你今天问过一次了,别老问能搜到的问题,这是 spam
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3859 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 44ms · UTC 05:08 · PVG 13:08 · LAX 22:08 · JFK 01:08
    ♥ Do have faith in what you're doing.