Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ng-toaster-rails

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ng-toaster-rails

  • 0.4.15.0
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

ng-toaster-rails

Gem Version

ng-toaster-rails wraps the AngularJS-Toaster library in a rails engine for simple use with the asset pipeline provided by Rails 3.1 and higher. The gem includes the development (non-minified) source for ease of exploration. The asset pipeline will minify in production.

For more info on customizing the library, please refer to the doc

Usage

Add the following to your gemfile:

gem 'ng-toaster-rails'

Add the following directive to your Javascript manifest file (application.js):

//= require toaster

If not present, also require ngAnimate module

//= require angular-animate

And the following directive to your Stylesheet manifest file (appliaction.css):

*= require toaster

Then, just follow the doc. Add toaster container directive:

<toaster-container></toaster-container>

Prepare the call of toaster method:

  angular.module('main', ['toaster'])
  .controller('myController', function($scope, toaster) {
      $scope.pop = function(){
          toaster.pop('success', "title", "text");
      };
  });

Call controller method on button click:

<div ng-controller="myController">
    <button ng-click="pop()">Show a Toaster</button>
</div>

Versioning

ng-toaster-rails 0.4.10 == AngularJS-Toaster 0.4.10

Every attempt is made to mirror the currently shipping AngularJS-Toaster version number wherever possible. The major, minor, and patch version numbers will always represent the AngularJS-Toaster version. Should a gem bug be discovered, a 4th version identifier will be added and incremented.

FAQs

Package last updated on 26 Jun 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc