breakfast 0.0.3 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 71e6cebca223c29c19ffd097ab723fbabb6abb97
4
- data.tar.gz: f665da4fd1e1e3c44019ca22d04f5330473955ad
3
+ metadata.gz: 81dc47bb8e920de4a76c9f9786c27bd477f276c5
4
+ data.tar.gz: fb19acceae3867db1b3646a4414e941733f1aefc
5
5
  SHA512:
6
- metadata.gz: 10efe24a8fb7a68eb6885d1abcf9fc6448247af777e627047b9dec616f25cb49ea535f4b31e6402161f755ff086b2ed0a2c60f9468d4e9b6a81d53c99f8dd27a
7
- data.tar.gz: 6ea160961218a2a00c1578aa3abadb3ae22379c00eaff1ae4019bc6b32c0af4ded2a292b2b70b4ea113e28e2344d3bec9ea81fa77a6b4f5b4d132f5adaf4cc7b
6
+ metadata.gz: 673231b3a2dea8137c755fe7c735c7d4e2a8b360b8ac5dbab7a50a5e788f83f96d7bf922465e90d15232f04fe0ed399d497a2707b38804d152c6d10c999570ae
7
+ data.tar.gz: 98a0f9223a3c68e60dc73a30a727cb06e4f6d59422c71bf1d62ce9c3e1ada5c53b55c375b967be326c624a2d4c6f47cff9f11f5b9ad4c6e525a80843aec19312
@@ -13,6 +13,7 @@ module BrunchRails
13
13
 
14
14
  config.breakfast.websocket_hostname = "localhost"
15
15
  config.breakfast.websocket_port = 3000
16
+ config.breakfast.environments = %w(development)
16
17
  end
17
18
 
18
19
  initializer "breakfast.setup_view_helpers" do |app|
@@ -1,3 +1,3 @@
1
1
  module Breakfast
2
- VERSION = "0.0.3"
2
+ VERSION = "0.0.4"
3
3
  end
@@ -1,12 +1,14 @@
1
1
  module Breakfast
2
2
  module ViewHelper
3
3
  def breakfast_autoreload_tag
4
- content_tag :script do
5
- <<-SCRIPT.html_safe
6
- window.Breakfast = window.Breakfast || {};
7
- window.Breakfast.liveReload = #{Rails.configuration.breakfast.live_reload};
8
- require("breakfast-rails").init();
9
- SCRIPT
4
+ if Rails.configuration.breakfast.environments.include?(Rails.env)
5
+ content_tag :script do
6
+ <<-SCRIPT.html_safe
7
+ window.Breakfast = window.Breakfast || {};
8
+ window.Breakfast.liveReload = #{Rails.configuration.breakfast.live_reload};
9
+ require("breakfast-rails").init();
10
+ SCRIPT
11
+ end
10
12
  end
11
13
  end
12
14
  end
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "breakfast-rails",
3
- "version": "0.0.3",
3
+ "version": "0.0.4",
4
4
  "description": "Assets for the Breakfast Gem",
5
- "main": "breakfast-rails.js",
5
+ "main": "src/breakfast-rails.js",
6
6
  "scripts": {
7
7
  "test": "echo \"Error: no test specified\" && exit 1",
8
8
  "compile": "babel --presets es2015 -d lib/ src/",
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: breakfast
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Patrick Koperwas
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-07-08 00:00:00.000000000 Z
11
+ date: 2016-07-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler