Giter Site home page Giter Site logo

Comments (5)

roscopeeco avatar roscopeeco commented on September 22, 2024

Some more info...

I am using ko.pureComputed and changed back to ko.computed to see if this had any effect.

When i did this i got the error 2 twice and the page elements for self.items.data did not load.

from knockout-deferred-updates.

roscopeeco avatar roscopeeco commented on September 22, 2024

I have checked out other scripts that i am loading (legacy ko widget libraries i have developed) and changed ko.computed to ko.pureComputed.

This resolves the issue and i am getting no errors on the page.

So ko.computed cannot be used with this plugin then?

thanks
Ross

from knockout-deferred-updates.

mbest avatar mbest commented on September 22, 2024

From your description, I'm not sure where the problem is coming from. Is it possible for you to put together an example of the failure?

from knockout-deferred-updates.

roscopeeco avatar roscopeeco commented on September 22, 2024

Hello Michael

Unfortunately the page i have developed is pretty complex with loads and loads of view models loaded and a large library of code supporting them.

All i can tell you is that using ko.pureComputed instead of ko.computed in all of my knockout view models has resolved the issue. I was unable to debug and identify the exact piece of my code that was responsible.

By the way this library has definately given the page a cleaner look when loading and speeded things up...thanks very much!!!!

cheers
Ross

from knockout-deferred-updates.

JohanAhlen avatar JohanAhlen commented on September 22, 2024

I get the same error, it could be related to the mapping plugin. I've also got quite a complex page but I stumbled upon this one when I added something like:

this.modelProp = ko.mapping.fromJS(anArray, {
  create: function(value) {
    var vm = ko.mapping.fromJS(value)
    vm.obs = ko.observable('foo');
    vm.comp = ko.computed(function() {
      return ["foo"];
    });
    return vm;
  }
});

I get the error when using the 'comp' computed in the page bindings (but not with the 'obs' observable).

Logging the currentFrame just before the error indicates that this could be a minification issue. Most of them have human readable properties like 'callback', 'computed' etc. But, the one causing the error have minified property names like 'Ca', 'La' and 'w'...

from knockout-deferred-updates.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.