Version: v0.6.1 - Beta.  We welcome contributors & feedback.  THanks!

Session.hasFlash

Session.hasFlash($key)

Description

Return true or false, indicating if the flash $key has been set for the current session via Session.setFlash.

// ... process user action ...

Session.setFlash('message', 'Congratulations!');


// ... in the NEXT request only ...

// In HTML template
-- if (Session.hasFlash('message')) {
    <div>{{ Session.getFlash('message') }}</div>
-- }

//= <div>Congratulations!</div>