Git Product home page Git Product logo

Comments (4)

rakeshpai avatar rakeshpai commented on August 10, 2024

I'm a little perplexed, since I can't understand how the components object in componentTracker.js could ever be populated when loadComponents is called. The hydration of the app itself comes after loadComponents is complete, so the app can't have populated the component cache yet. So, when calling loadComponents, the components object will always be empty.

I'm pretty sure I'm doing something wrong. :)

from loadable-components.

stereobooster avatar stereobooster commented on August 10, 2024
const snapSaveState = () => {
  document.querySelector('html').setAttribute(
    'data-snap-state',
    JSON.stringify(getState())
  );
};

not sure where you got this snippet from. Use exact code from readme:

window.snapSaveState = () => getState();

UPD:

I'm using a tool similar to react-snap, and can verify that I'm setting

I missed that part

from loadable-components.

gregberge avatar gregberge commented on August 10, 2024

The current version of loadable-components has some issues with registering. I have to rewrite that part to handle all cases.

from loadable-components.

gregberge avatar gregberge commented on August 10, 2024

This issue should be solved in v1. You should give a try, feel free to open a new issue if you experienced any problem.

from loadable-components.

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.