TangMonk
V2EX  ›  Node.js

mocha 一个怪异的问题

  •  
  •   TangMonk · Aug 30, 2014 · 4122 views
    This topic created in 4451 days ago, the information mentioned may be changed or developed.
    放代码不方便,我直接放 gif 了,很短。



    tag.js 加载不了 location.js 里的 hello()
    5 replies  •  2014-09-07 09:25:07 +08:00
    assassinpig
    assassinpig
    Aug 30, 2014❤️1
    1
    把代码贴上好不?
    assassinpig
    assassinpig
    Aug 30, 2014❤️1
    2
    exports.hello = hello;
    iwege
    iwege
    Aug 30, 2014❤️1
    3
    1.20.1
    同样的代码,没有 debugger 使用`mocha tag.js` 跑, 没问题。
    TangMonk
    TangMonk
    OP
    Aug 31, 2014
    4
    谢谢各位, 我知道怎么回事了
    是Cycles dependent 的问题

    tag.js -> location.js

    location.js -> tag.js
    fritx
    fritx
    Sep 7, 2014
    5
    蛋疼 怎么 有 console.log(hello) 啊?
    location.js 里 helllo is not defined 啊
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   1843 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 26ms · UTC 09:21 · PVG 17:21 · LAX 01:21 · JFK 04:21
    ♥ Do have faith in what you're doing.