• I have an embedded react app in my admin area that uses a hash-based router.

    Using WPPCP, it throws javascript errors and won’t load the page.

    That’s because of this line, in js/wppcp-admin.js:
    520 $(hash_key).addClass(‘wppcp-info-setting-active’);

    It assumes a hash fragment in the URL directs to an anchor link – that isn’t true when using a hash router, so jQuery throws errors when it can’t find a matching DOM element.

    I can obviously comment out that line, but it doesn’t survive a plugin upgrade.

The topic ‘WPPCP javascript breaks hash routing’ is closed to new replies.