title: Best way to create user notifications on webpage in ASP.NET MVC 4 Razor
body: <p>tl:dr -> User notification system on website. Can you avoid the need to call a javascript script to render notifications after ajax loads? (a base view that calls it would work, but there are no base views afaik)</p>
  
  <p>I am looking for a way to add a User Notification System to my website. Such system would be responsible for displaying messages like 'Import success', 'Import failed', 'Session timed out' etc. </p>
  
  <p>I know similar questions have been answered before, but here's my question:</p>
  
  <ul>
  <li>How should I do it to get as close as possible to having the notifications display themselves as soon as possible after being put to TempData? Having them rendered on _layout page would work, but only for requests that ask for whole page. What about loading only parts of website through ajax -> can I avoid having to write JS script in ajax callbacks or partial views?
  I am looking for something to prevent writing multiple calls to same function.</li>
  </ul>