Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Nov 17 21:58
  • Nov 14 17:40
    nlundquist edited #5424
  • Nov 14 17:40
    nlundquist edited #5424
  • Nov 14 17:39
    nlundquist opened #5424
  • Nov 14 17:39
    nlundquist review_requested #5424
  • Nov 14 17:39

    nlundquist on 107-update-converter-demos

    update can-stache-converters de… (compare)

  • Nov 14 14:32
    greenkeeper[bot] labeled #5423
  • Nov 14 14:32
    greenkeeper[bot] opened #5423
  • Nov 14 14:32

    greenkeeper[bot] on can-route-5.0.1

    fix(package): update can-route … (compare)

  • Nov 13 13:09

    greenkeeper[bot] on steal-tools-2.2.3

    (compare)

  • Nov 13 12:55

    greenkeeper[bot] on steal-tools-2.2.3

    chore(package): update steal-to… (compare)

  • Nov 13 01:44

    greenkeeper[bot] on @webcomponents

    (compare)

  • Nov 13 01:42

    greenkeeper[bot] on @webcomponents

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

  • Nov 12 05:28
    greenkeeper[bot] commented #5392
  • Nov 12 05:28

    greenkeeper[bot] on core-js-3.4.1

    chore(package): update core-js … (compare)

  • Nov 11 18:03
    greenkeeper[bot] labeled #5422
  • Nov 11 18:03
    greenkeeper[bot] opened #5422
  • Nov 11 18:03

    greenkeeper[bot] on @feathersjs

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

  • Nov 11 18:02
    greenkeeper[bot] commented #5401
  • Nov 11 18:02

    greenkeeper[bot] on @feathersjs

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

Vojtech Prikryl
@Aldredcz
then I have events listening to changes in subRule.operator and subRule.subject, according to them, it modifies other attributes of subRule. And according to that, initTags and initSelect is rendered,.. but those helpers are called before event callbacks
Vojtech Prikryl
@Aldredcz
already solved it ... had operator and subject bound by can-value on <select>, so changed it to can-change and handled all the changes in can.batch, so I'm always in valid state... but once I would need to react to changes from other controller and not from view,.. dunno how I would solve it..
Marshall Thompson
@marshallswain
@matthewp Yes, still using 2.1.4, so can-compile’ing the views for a few more days.
Vojtech Prikryl
@Aldredcz

Was just diggin in lib files, this is in view/scanner.js:

// Escapes characters starting with `\`.
        clean = function (content) {
            return content
                .split('\\')
                .join("\\\\")
                .split("\n")
                .join("\\n")
                .split('"')
                .join('\\"')
                .split("\t")
                .join("\\t");
        },

You sure that's the best way how to escape chars in terms of performance?

Matthew Phillips
@matthewp
where is that?
oh, view/scanner
probably not the best way
i wonder how often this function gets called
but you're right
PRs welcome :)
Justin Meyer
@justinbmeyer
@Aldredcz you should really switch to stache
@Aldredcz you can check ev.batchNum
var lastBatchNum
bind("EVENT", function(ev){
  if(ev.batchNum === undefined || ev.batchNum !== lastBatchNum) { 
    lastBatchNum = ev.batchNum

    DO STUFF
 }
Vojtech Prikryl
@Aldredcz
@justinbmeyer Yea, slowly migrating whole app from ejs to stache,..
about batchNum - I know it and use it a lot, but this is not the case,.. I was asking if i can control somehow order of events 'helper live bound update' and 'event live bound update' in Component
Justin Love
@JustinLove
An inner component changes the state of the server. What is a good way to tell the parent components to refresh their data?
Matthew Phillips
@matthewp
@JustinLove There's currently some work to be done to make this better
I think for now you might need to do
this.element.parent().scope().refreshData()
or something likethat
Justin Love
@JustinLove
Thanks. I ended up firing an event; I had trouble with that at first because foundation dialogs get moved to body, which changed the bubbling chain.
Can I make can.view do #id lookup only, without a web request if isn't found?
Justin Love
@JustinLove
Are there complex examples of can.route?
Justin Meyer
@justinbmeyer
@JustinLove https://github.com/bitovi/steal-can-example/blob/master/main.js is a small but complex example
what kind of example are you looking for?
Justin Meyer
@justinbmeyer
If you were using the #minor branch, it had everything in a "lib" folder. That is now gone in master. So if you were using that structure, you will need to change your paths configuration to point to the new location.
Justin Meyer
@justinbmeyer
@alexisabril regarding your pushstate question ...
do you need to return the data?
sorry, the html
Alexis Abril
@alexisabril
nope
just looking to ignore /foo/bar/baz from the node side
Justin Meyer
@justinbmeyer
Ok, so you just need to handle all incoming urls
Alexis Abril
@alexisabril
not really canjs specific
Justin Meyer
@justinbmeyer
oh, but not sure how to do it?
Alexis Abril
@alexisabril
yep, totally lazyweb
app.use('/', serveStatic(__dirname))
.use(function(req, res) {});
Justin Meyer
@justinbmeyer
what framework?
express
Alexis Abril
@alexisabril
connect; that noop needs a res.end(), however calling end will actually overwrite the existing html
Justin Meyer
@justinbmeyer
calling end?
oh, res.end
it actually writes the existing html?
oh, b/c you are serving static
Alexis Abril
@alexisabril
the static section is irrelevant for this case actually; one possible solution is to redirect all incoming requests to a specified index.html or redirect to a #! + request path
Curtis Cummings
@ccummings
There's a third param to a middleware function called next. Call that at the end of handling your route instead end to let the next middleware take over
instead of*
Alexis Abril
@alexisabril
true, however that'll eventually timeout since no response is returned
Matthew Phillips
@matthewp
@justinbmeyer should package.json main point to dist/cjs/can.js?
"browser" doesn't handle the main does it?
Curtis Cummings
@ccummings
Is it possible to get a 2.2.0-pre published to npm? I'm interested in seeing what the npm release will look like in a Browserify environment. Will I still need a ton of browser mappings to require things like can/construct/proxy
Matthew Phillips
@matthewp
:+1: i want the same thing