Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add dynamic var for warning on handler overwrite #413

Closed
wants to merge 1 commit into from

Commits on Nov 6, 2016

  1. Add dynamic var for warning on handler overwrite

    When figwheel reloads code, it causes handlers to be re-registered
    which leads to a warning for each handler. This leads to noisy logs.
    Figwheel has a :before-jsload key which can be called before it reloads
    application code.
    
    This patch adds a *warn-on-overwrite* dynamic var, and shows how to use
    it in the example project.
    
    One side effect of using this is that you will never get a warning
    for duplicate handlers when Figwheel is reloading. It may be possible
    to track how many handlers were reloaded in a particular Figwheel
    reload, but this would get very complex. In any case, you will still
    get warnings every time you refresh the browser, which should be good
    enough for the relatively rare case of creating duplicate handlers.
    
    Fixes #204
    danielcompton committed Nov 6, 2016
    Configuration menu
    Copy the full SHA
    8de4175 View commit details
    Browse the repository at this point in the history