These are chat archives for canjs/canjs

7th
Dec 2015
Mihai Fantana
@fantanamihai
Dec 07 2015 07:37

latest canjs version. I'm facing an infinite loop bug here when including can/view/modifiers. The following example reproduces the issue:

  can.Control.extend('Test', {
    hookup: function(el) {
      return new this(el);
    }
  }, {
    setup: function(el, options){ 
        var newElem = $('<div/>');

        $(el).wrap(newElem);
        this._super.call(this, newElem, options);
    }
  });

The Test control is called through an EJS template:

<script id="ejsTemplate" type="text/ejs">
  <div><%= Test %></div>
</script>

I cannot understand what am I missing. Can you please help?

you can see it in action in http://jsfiddle.net/meconjs/kq9q6Lep/
Mason Shin
@minsooshin
Dec 07 2015 17:19
@pYr0x but when I use jquery $.get or can.ajax for custom ajax, it works fine.
Justin Meyer
@justinbmeyer
Dec 07 2015 19:29
@meconcomputer did you create an issue?
I think I saw one
btw, modifiers isn't used much anymore
do you need it?
Gerard Finnerty
@halcyonandon
Dec 07 2015 20:12
Hi, we're having a discussion about what documentation generator to use... Trying to determine the advantages of using your documentjs over https://github.com/documentationjs
Gerard Finnerty
@halcyonandon
Dec 07 2015 20:18
at v0.3.6, is there any major changes in the pipeline? also, I'm trying to see if there's any canjs-specific advantages
Alfredo Delgado
@Alfredo-Delgado
Dec 07 2015 20:35
Are there any known problems with a SuperMap accepting parameters in the URL? e.g. url: '/{baseSiteId}/{countryCode}/products/global-navigation',
David Luecke
@daffl
Dec 07 2015 21:21
Are you getting an error?