Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Sep 21 21:15
    greenkeeper[bot] commented #5237
  • Sep 21 21:15

    greenkeeper[bot] on @feathersjs

    chore(package): update @feather… (compare)

  • Sep 21 21:12
    greenkeeper[bot] commented #5236
  • Sep 21 21:12

    greenkeeper[bot] on @feathersjs

    chore(package): update @feather… (compare)

  • Sep 21 03:58

    greenkeeper[bot] on @octokit

    (compare)

  • Sep 21 03:57

    greenkeeper[bot] on @octokit

    chore(package): update @octokit… (compare)

  • Sep 20 21:04
    m-mujica commented #5303
  • Sep 20 20:23
    m-mujica opened #5303
  • Sep 20 20:23

    m-mujica on upgrade-deps

    Update can-type and can-stache-… (compare)

  • Sep 20 20:05
    m-mujica edited #5302
  • Sep 20 20:03
    m-mujica synchronize #5302
  • Sep 20 20:03

    m-mujica on upgrade

    Upgrade routing guide to Can 6 Fix incorrect highlight Use svg images (instead of .png) (compare)

  • Sep 20 19:32
    m-mujica opened #5302
  • Sep 20 19:29

    m-mujica on upgrade

    Upgrade routing guide to Can 6 Fix incorrect highlight (compare)

  • Sep 20 17:42

    m-mujica on upgrade

    WIP: Upgrade (compare)

  • Sep 20 17:06
    do-adams starred canjs/canjs
  • Sep 20 13:34

    chasenlehara on 5119-testing-guide

    Update the Testing guide for Ca… (compare)

  • Sep 20 13:21
    cherifGsoul commented #5295
  • Sep 20 13:18
    cherifGsoul synchronize #5295
  • Sep 20 13:18

    cherifGsoul on update-theme-new-buttons

    Theme pre-release 2 (compare)

Morgan Heimbeck
@Xitstrategies
We do can.view.preload before we instantiate the outer template.
steal(‘can’,
‘outer.stache!’,
’inner.stache!’,
function(OuterView, InnerView) {
can.view.preload(‘inner-template’, InnerView);
return can.component.extend({
tag: ’test-tag’,
template: OuterView
});
});
Alexis Abril
@alexisabril
@Xitstrategies Ah, good call
Matthew Phillips
@matthewp
@alexisabril @Xitstrategies in 2.3 you can use can-import to import partials
there is a test for it... one sec
dylanrtt
@dylanrtt
I'm using Webstorm with the Handlebars plugin and noticed the new reference scope bindings are a bit of a problem because * is seen as invalid syntax in mustache (same with %). For example, {{myHelper *foo}} produces the error "Expected Close }}". Has anyone figured out a way around this or created a modified version of the plugin?
Gerard Finnerty
@halcyonandon
Hi, ran into an odd bug, still investigating it, but I'm curious if anyone else experienced this... when using viewModel attrs for event bindings inside a component like events: { '{viewModel} errors.someField.showErrors': function(e, ev) {}} ...for some reason, if this event fires off more than a half dozen or so times, it just stops working, stops executing, no js errors... when i trace through, that attr still gets set (on field focus), but that function just stops executing... when I move the code from there into the field focus event, there is no issue
Justin Meyer
@justinbmeyer

@here - is there a way to prevent a can.Control from hooking up one of the templated event handlers? I have a "#fileInput change" that I want to prevent from being wired up if condition isn't met (in which case I will manually wire the event to a polyfill).

ryan [4:36 PM]
I will also take care to remove the manual binding during teardown - I just didn't know if setup allowed for that kind of thing.

there is not. I would not use a templated event binding and instead us .on() inside init.
Ryan Wheale
@DesignByOnyx
ok, thanks for that.
Alexis Abril
@alexisabril
@DesignByOnyx if it's a common thing you're doing, you could also setup a custom processor. "#fileInput conditionalChange". You might need to address a syntax to pass conditions if those aren't set anywhere accessible(control options, element data, etc).
Ryan Wheale
@DesignByOnyx
Thanks for that @alexisabril. Doing it during initialization (using .on) is working best as it's clearer what's going on (no pun intended). can is still taking care of managing the event binding in most cases... which is what I wanted.
Ryan Wheale
@DesignByOnyx
So using .on() invokes handlers with an "event" parameter only - whereas CanJS templated event handlers get (element, event)parameters. This is actually convenient, but worthy of noting as the method signature has to be updated.
... when switching from templated to manual bindings.
Marshall Thompson
@marshallswain
@here With can-connect, if I want supermap functionality but I want to override getList to use feathersjs/feathers-client, is there a simple way to do that? Or do I need to start fresh and put the behaviors together manually?
Mihai Fantana
@fantanamihai
hi guys. can you please tell me if there are other options for findAll to return Array not Model.List, than models() and findAll() { return $.ajax} ?
Mihai Fantana
@fantanamihai
I am asking because we are migrating an old solution from jsmvc 3.2 to newest canjs. in jsmvc3.2 almost everytime we had a findAll, an Array was returned so we have a couple of Array methods called on data in all the project
David Luecke
@daffl
@meconcomputer Which can.List should also provide right?
Mihai Fantana
@fantanamihai
@daffl thanks for trying to understand :) We solved the problem by extending Model.List.prototype with the few Array methods we used
mpal9000
@mpal9000
Hello, is there any syntax highlighting package for sublime and other editors for *.component files of donejs?
Mihai Fantana
@fantanamihai
hi guys. canjs 2.2.9. the thing is that in our old app we are using models with get/set per attributes a lot. I found out that there is can/map/setter. Is there any reason no 'can/map/getter' is available ?
I know about 'define', but before that, what was the way to have a getter in a model?
David Luecke
@daffl
@mpal9000 I usually just set it to HTML or HTML + Handlebars if your editor supports it. If it can't do <viewmodel> tags then you can also fall back to <script type="viewmodel"> to get JS highlighting.
@meconcomputer The way to do getters in 2.2.9 is define. I think it should work together with the setter plugin although it would make sense to eventually migrate (it's much more powerful)
Mihai Fantana
@fantanamihai
@daffl thanks for the answer. We try to postpone and we will get to define later. How was getter in 2.1?
mpal9000
@mpal9000
@daffl ok thanks
Justin Meyer
@justinbmeyer
@meconcomputer you could add a can.compute to the prototype
and that could act like a getter
but please don't do that
use define :-)
migrating your setters should be straightforward
I believe they have the same signature
if you had setFoo: function(...) { ... }
you just change that to
define : {
  foo: {
    set: function(...){ ... }
  }
}
Mihai Fantana
@fantanamihai
@justinbmeyer i guess we will have to do that. thanks
Paulius
@paulius005
Im assuming you guys have abandoned canui
Matthew Phillips
@matthewp
no
but it needs a maintainer
David Luecke
@daffl
I hate to disagree but I would say yes ;) It hasn't been touched in three years and many things it was supposed to solve are now supported by the browser.
espretto
@espretto
hey,
espretto
@espretto
quick question: how can one make observable changes/events bubble up the component tree? i tried passing down an observable via component-tag attributes e.g. <child-component attr="parentObservable"> and it works as expected. It does however feel kind of weird if attr's is a computed property implemented within the child component. it seems the child overriddes the parent's possibly stubbed/non-existant implementation. any clue on this?
Ilya Fadeev
@ilyavf
can.stache("{{name}}").({name: "Name"}) returns a document fragment. How can I get a string value of it?
Justin Meyer
@justinbmeyer
why do you need a string?
Ilya Fadeev
@ilyavf
to use stache with other libraries (e.g. d3)
basically, i want to pass to my component that uses d3 a template that d3 will render its way.
Justin Meyer
@justinbmeyer
@espretto I'm not sure what you mean exactly by "attr's is a computed property implemented within the child component. it seems the child overriddes the parent's possibly stubbed/non-existant implementation."
Matthew Phillips
@matthewp
insert the fragment into a div and use div.innerHTML
Justin Meyer
@justinbmeyer
@ilyavf why do you need a string?
Ilya Fadeev
@ilyavf
@justinbmeyer to use stache with other libraries (e.g. d3: basically, i want to pass to my component that uses d3 a template that d3 will render its way)