Skip to content
This repository was archived by the owner on Apr 16, 2019. It is now read-only.

Release v0.5.9

Choose a tag to compare

@caridy caridy released this 29 Jul 22:48
· 172 commits to master since this release
  • using express-state to augment the express app
  • making expose middleware connect/express compatible
        // using it for a mounted middleware
        app.use(yui.expose());

        // or using it as a route middleware
        app.get('/foo', yui.expose());
  • adding debug middleware to control it per request
        // exposing yui into the client side thru `state` object
        app.use(yui.expose());
        // using yui in debug mode when node runs in debug mode with custom filter
        if (app.get('env') === 'development') {
            app.use(yui.debug({filter: 'raw'}));
        }

Note: the debug() middleware only works if it is called after the regular expose() middleware was called, otherwise it will not be able to overrule the default yui config for the app.

Deprecation

  • app.yui.debugMode() method is now deprecated in favor of a middleware that can set up the debug mode per request thru expyui.debug().