Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Alex
    @whitecolor
    @justinbmeyer yes propably it will be good to have this as additional feature for now with define plugin, as soon as this bitovi/canjs#1425 will be merged, it will be convinient to define such comon behaviour for all attributes.
    Justin Meyer
    @justinbmeyer
    @whitecolor did you get my email?
    Alex
    @whitecolor
    I think what canjs really lacks it build (via plugin, but out of the box) animation support. Have you thought about API and implementation for this? I currently use component that is animation container, that works pretty well for me, but still think there should be something build-in.
    Justin Meyer
    @justinbmeyer
    Alex
    @whitecolor
    @justinbmeyer it doesn't suupport custom css animations
    Justin Meyer
    @justinbmeyer
    @whitecolor it does
    but not via a className
    Alex
    @whitecolor
    where is the lates canjs master or minor currently?
    Alex
    @whitecolor
    what does this warnking mean WARN: Custom tag: web-appis already defined
    Justin Meyer
    @justinbmeyer
    @whitecolor you have the same component defined twice
    @/all syn is finally on npm: https://www.npmjs.com/package/syn
    If you are using the 0.7.0 of stealjs, you can simply npm install syn --save
    and in your apps
    import syn from "syn"
    syn.click($("li")[1]);
    Alex
    @whitecolor
    @justinbmeyer is it possible reinitialize component on the element completly?

    so fi I have in template

    <my-component param="{param}"></my-component>

    can takes this this element and initialize component on it (puts scope, renders template inside, etc.
    And after it has beed already done once, I want to take this element and remove component stuff (scope, events, template) be removed from the element and be initialized again in correct manner. Is this possible somehow?

    Justin Meyer
    @justinbmeyer
    @whitecolor why do you want that?
    Alex
    @whitecolor
    @justinbmeyer for component hot refresh. after redefine of comonnent's code I wan't to try just reinitilaze component on the page instead of whole application.
    Alex
    @whitecolor
    to get something like this https://vimeo.com/100010922
    Justin Meyer
    @justinbmeyer
    @whitecolor are you sure that is not re-doing almost all initialization?
    It's possible to probably destroy a component
    similar to a can.Control
    (maybe)
    I worry about the passed subtemplate (that's accessible via <content>)
    Alex
    @whitecolor
    @justinbmeyer Actually I've managed to to this, I trigger 'removed' event on the element that removes all the bindings and manually empty HTML, and then init component on the element again with the same hookupOptions. Seem to work. Though react-hot-loader replaces parts of their component without destoroying existing instance, but there is another more simple architecture without events and different approach to rendering.
    And yes I didn't check it for components with <content> yet.
    Alex
    @whitecolor
    is it possible to set attr on scope in can event with param? can-click="{@scope.attr 'tab' 'first'}" seems not to work.
    Justin Meyer
    @justinbmeyer
    that syntax should work, but is a mistake/ bug
    it should be
    can-click="{@viewModel.attr 'tab' 'first'}"
    @scope should be the can.view.Scope
    also, you could do @context.attr
    @whitecolor
    Alex
    @whitecolor
    @justinbmeyer ok thanks
    Marshall Thompson
    @marshallswain
    @whitecolor Your avatar sports the cleanest design I’ve ever seen. (not seen?)
    Alex
    @whitecolor
    right
    Alex
    @whitecolor
    @justinbmeyer Hey maybe it would be better to retarget this room for canjs (or make new one for it), call people here.
    a question: is there a way to bind to change of particular attribute for each of list items?
    Justin Meyer
    @justinbmeyer
    @whitecolor there is a canjs room
    please ask CanJS questions there
    Alex
    @whitecolor
    @justinbmeyer ok I didn't know
    Mason Shin
    @minsooshin
    @justinbmeyer I cannot find the room search by canjs….what I need to type?
    Justin Meyer
    @justinbmeyer
    There's also a donejs room now: https://gitter.im/donejs/donejs
    for questions that span multiple libraries
    Mason Shin
    @minsooshin
    cool thanks
    see you at the donejs meetup at silicon valley :)
    Justin Meyer
    @justinbmeyer
    sounds great :-)
    apsignifi
    @apsignifi
    Hi Justin,
    • migrating from 2.3 to 3.00
    • using daterangepicker.
      changed from
      can.trigger($('.dateranger input.start'), 'change');
      to
      canBatch.dispatch($('.dateranger input.start'), 'change');
    getting this error :
    Arguments to dispatch should be an array
    do you have an idea how to handle this ?
    Justin Meyer
    @justinbmeyer
    @apsignifi you might want to ask questions in: https://gitter.im/canjs/canjs