Socket
Book a DemoInstallSign in
Socket

heap-helpers

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

heap-helpers

0.1.0
bundlerRubygems
Version published
Maintainers
1
Created
Source

Heap Helpers for Ruby

Build Status Coverage Status Dependency Status Yard Docs Gem Version

This Ruby gem contains helpers for embedding the heap.js snippet used to instal Heap on a site.

Prerequisites

This gem is tested on Ruby 1.8.7 and above, and is expected to work with Rails 2.3.8 and above. The gem depends on the official heap gem.

Installation

If you're using bundler, add the following line to your Gemfile.

gem 'heap-helpers'

Otherwise, install the heap-helpers gem and activate it in your code manually.

gem install heap
require 'heap-helpers'

Setup

Follow the instructions for the heap gem.

Usage

Add the following in your layouts or views, before the closing </head> tag. In a typical Ruby on Rails application, this change would go into app/views/layouts/application.html.erb.

<%= Heap.javascript_tag %>

The helper supports advanced heap.js options.

<%= Heap.javascript_tag force_ssl: true %>

You can also specify advanced options in the initialization code. This is especially useful if you're using the same helper in multiple places in your code.

Heap.app_id = 'YOUR_APP_ID'
Heap.js_options = { force_ssl: true }

Copyright (c) 2016 Victor Costan, released under the MIT license.

FAQs

Package last updated on 01 Mar 2016

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

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.