There were two things I couldn’t quite understand:
get-list="{ period='previous_week' }" what is get-list and what is that strange syntax on the right side? is it an object? if so does it mean I could have my-function-name="{ param1=this.var1 param2=this.var2}"?
the use of * in the binding: I think it was previously explained to me that it had to do with some sort of “temporal” element to connect both the order-model with bit-c3-data-column without using a real property. There is an explanation here https://canjs.com/doc/can-stache-bindings.reference.html#Use but still I barely understand how to use it and its benefits.
You can use hash expressions to make something like on:click="myFunction(param1=var1 param2=var2)" call myFunction({param1: var1, param2: var2})
* (in CanJS 3) can be used to take a value from a child component and make it usable elsewhere in the template. You can always do that by creating a property in the template for the view model, but with * you don’t have to create that extra property. These docs have a little more info: https://canjs.com/doc/can-stache-bindings.toParent.html#ExportingViewModelproperties
We’re deprecating the * syntax in CanJS 4 so that it’s more clear what’s going on. You can start using scope.vars to accomplish the same thing in can-stache 3.11+
Just to be sure, this <order-model get-list="{ period='previous_week' }" value:to="*previousWeek" /> is equivalent to have a getter in the viewmodel that calls the getList method (returns a Promise) with params defined as { period='previous_week' } ?