stimulus_reflex 3.3.0.pre2 → 3.3.0.pre3

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of stimulus_reflex might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 16b54837068db127425aef4bb7d055fb461ed06cfd1693a1303f4b2e7c8e94d2
4
- data.tar.gz: 23cb0849034978ecae65551b069f0173d9a63fd78db7233b11e4453be752cb48
3
+ metadata.gz: 7573abb6ad8e3dbf3a7512084be5947c17fcb3ce55fe37b75372702f6372aa45
4
+ data.tar.gz: 14b658def13f3052406398c6607bef62eded64f048ca1e69a053902e11b9ab4d
5
5
  SHA512:
6
- metadata.gz: 88f1f347aad5757ee0f2420f4d781626f759f2bd00ed8392f101d52fd813e1e6e1ae9cbfde1fa3954332ad55766569cb1bcf33a56d1dc26b952057e60f97ad7b
7
- data.tar.gz: eadb6be440d20ab3183e373e07579fbd7462d2b2fab06c60a80a0d9991c7003f10674e6696eb34e30e320e359b544bc8d25b9c0252bb251cb0d8a32f5946d766
6
+ metadata.gz: 02bff2943495c27165b4609f877904496f6b5d488e17b08f9e4e1aea5c53f5be1b8c8411ac8d07391704ceac08b1c7a59e44c216221735cabccbbfc6d56ee0f2
7
+ data.tar.gz: ee4bcdb5885070e1cb8b5f90964c4cde12b3c0a1125bb1556ecf21857247da21344e4f86655586b90742a8b76ef594aecbe3150ea06c82bd5ec5fc0509feecb7
@@ -2,7 +2,39 @@
2
2
 
3
3
  ## [Unreleased](https://github.com/hopsoft/stimulus_reflex/tree/HEAD)
4
4
 
5
- [Full Changelog](https://github.com/hopsoft/stimulus_reflex/compare/v3.3.0.pre1...HEAD)
5
+ [Full Changelog](https://github.com/hopsoft/stimulus_reflex/compare/v3.3.0.pre2...HEAD)
6
+
7
+ **Fixed bugs:**
8
+
9
+ - First argument of type "object" in this.stimulate\(\) will always be assigned to options. [\#278](https://github.com/hopsoft/stimulus_reflex/issues/278)
10
+ - Allow morphs to run before triggering success/after [\#286](https://github.com/hopsoft/stimulus_reflex/pull/286) ([hopsoft](https://github.com/hopsoft))
11
+
12
+ **Closed issues:**
13
+
14
+ - Reflex ignores turbolinks cached pages [\#288](https://github.com/hopsoft/stimulus_reflex/issues/288)
15
+ - Issue with Stimulus Reflex and ViewComponent [\#284](https://github.com/hopsoft/stimulus_reflex/issues/284)
16
+ - controller inheritance does not seem to work [\#283](https://github.com/hopsoft/stimulus_reflex/issues/283)
17
+ - Cannot read property 'schema' of undefined [\#282](https://github.com/hopsoft/stimulus_reflex/issues/282)
18
+ - Reflex on form submit does not get parameter from input\[type="file"\] [\#277](https://github.com/hopsoft/stimulus_reflex/issues/277)
19
+ - jQuery Plugins [\#246](https://github.com/hopsoft/stimulus_reflex/issues/246)
20
+ - ActiveStorage variants performance [\#242](https://github.com/hopsoft/stimulus_reflex/issues/242)
21
+ - Unnecessary body update after text\_content [\#186](https://github.com/hopsoft/stimulus_reflex/issues/186)
22
+ - Warn about enabling Rails after running stimulus reflex' initializer [\#185](https://github.com/hopsoft/stimulus_reflex/issues/185)
23
+ - Integration tests for stimulus-reflex [\#162](https://github.com/hopsoft/stimulus_reflex/issues/162)
24
+ - Clearer explanation of quickstart example without javascript. [\#149](https://github.com/hopsoft/stimulus_reflex/issues/149)
25
+ - Webpack compilation fails with rails/webpacker 3.6 [\#83](https://github.com/hopsoft/stimulus_reflex/issues/83)
26
+
27
+ **Merged pull requests:**
28
+
29
+ - Check if reflex exists before using it [\#293](https://github.com/hopsoft/stimulus_reflex/pull/293) ([joshleblanc](https://github.com/joshleblanc))
30
+ - Add instructions for existing projects [\#291](https://github.com/hopsoft/stimulus_reflex/pull/291) ([gerrywastaken](https://github.com/gerrywastaken))
31
+ - Fix argument of type object always being assigned to options [\#279](https://github.com/hopsoft/stimulus_reflex/pull/279) ([shawnleong](https://github.com/shawnleong))
32
+ - Simplify devise authentication logic \(in docs\) [\#276](https://github.com/hopsoft/stimulus_reflex/pull/276) ([inner-whisper](https://github.com/inner-whisper))
33
+ - Bump lodash from 4.17.15 to 4.17.19 in /javascript [\#275](https://github.com/hopsoft/stimulus_reflex/pull/275) ([dependabot[bot]](https://github.com/apps/dependabot))
34
+
35
+ ## [v3.3.0.pre2](https://github.com/hopsoft/stimulus_reflex/tree/v3.3.0.pre2) (2020-07-17)
36
+
37
+ [Full Changelog](https://github.com/hopsoft/stimulus_reflex/compare/v3.3.0.pre1...v3.3.0.pre2)
6
38
 
7
39
  **Closed issues:**
8
40
 
@@ -200,7 +232,6 @@
200
232
  - Some housekeeping [\#189](https://github.com/hopsoft/stimulus_reflex/pull/189) ([hopsoft](https://github.com/hopsoft))
201
233
  - Allow to call stimulate without a reflex target [\#188](https://github.com/hopsoft/stimulus_reflex/pull/188) ([marcoroth](https://github.com/marcoroth))
202
234
  - Fix bug in super documentation [\#174](https://github.com/hopsoft/stimulus_reflex/pull/174) ([silva96](https://github.com/silva96))
203
- - Support devise authenticated routes [\#172](https://github.com/hopsoft/stimulus_reflex/pull/172) ([db0sch](https://github.com/db0sch))
204
235
 
205
236
  ## [v3.1.4](https://github.com/hopsoft/stimulus_reflex/tree/v3.1.4) (2020-04-27)
206
237
 
@@ -228,6 +259,7 @@
228
259
 
229
260
  - prettier-standard: include all js files in the project [\#177](https://github.com/hopsoft/stimulus_reflex/pull/177) ([marcoroth](https://github.com/marcoroth))
230
261
  - Remove implicit permanent for text inputs [\#176](https://github.com/hopsoft/stimulus_reflex/pull/176) ([hopsoft](https://github.com/hopsoft))
262
+ - Support devise authenticated routes [\#172](https://github.com/hopsoft/stimulus_reflex/pull/172) ([db0sch](https://github.com/db0sch))
231
263
  - setupDeclarativeReflexes export with UJS support [\#169](https://github.com/hopsoft/stimulus_reflex/pull/169) ([leastbad](https://github.com/leastbad))
232
264
  - Fix compilation issue [\#168](https://github.com/hopsoft/stimulus_reflex/pull/168) ([jonathan-s](https://github.com/jonathan-s))
233
265
 
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- stimulus_reflex (3.3.0.pre2)
4
+ stimulus_reflex (3.3.0.pre3)
5
5
  cable_ready (>= 4.1.2)
6
6
  nokogiri
7
7
  rack
@@ -70,14 +70,14 @@ GEM
70
70
  cable_ready (4.3.0)
71
71
  rails (>= 5.2)
72
72
  coderay (1.1.3)
73
- concurrent-ruby (1.1.6)
73
+ concurrent-ruby (1.1.7)
74
74
  crass (1.0.6)
75
75
  erubi (1.9.0)
76
76
  globalid (0.4.2)
77
77
  activesupport (>= 4.2.0)
78
- i18n (1.8.3)
78
+ i18n (1.8.5)
79
79
  concurrent-ruby (~> 1.0)
80
- loofah (2.6.0)
80
+ loofah (2.7.0)
81
81
  crass (~> 1.0.2)
82
82
  nokogiri (>= 1.5.9)
83
83
  mail (2.7.1)
@@ -133,19 +133,19 @@ GEM
133
133
  rake (13.0.1)
134
134
  regexp_parser (1.7.1)
135
135
  rexml (3.2.4)
136
- rubocop (0.85.1)
136
+ rubocop (0.89.1)
137
137
  parallel (~> 1.10)
138
- parser (>= 2.7.0.1)
138
+ parser (>= 2.7.1.1)
139
139
  rainbow (>= 2.2.2, < 4.0)
140
140
  regexp_parser (>= 1.7)
141
141
  rexml
142
- rubocop-ast (>= 0.0.3)
142
+ rubocop-ast (>= 0.3.0, < 1.0)
143
143
  ruby-progressbar (~> 1.7)
144
144
  unicode-display_width (>= 1.4.0, < 2.0)
145
- rubocop-ast (0.1.0)
146
- parser (>= 2.7.0.1)
147
- rubocop-performance (1.6.1)
148
- rubocop (>= 0.71.0)
145
+ rubocop-ast (0.3.0)
146
+ parser (>= 2.7.1.4)
147
+ rubocop-performance (1.7.1)
148
+ rubocop (>= 0.82.0)
149
149
  ruby-progressbar (1.10.1)
150
150
  sprockets (4.0.2)
151
151
  concurrent-ruby (~> 1.0)
@@ -154,9 +154,9 @@ GEM
154
154
  actionpack (>= 4.0)
155
155
  activesupport (>= 4.0)
156
156
  sprockets (>= 3.0.0)
157
- standard (0.4.7)
158
- rubocop (~> 0.85.0)
159
- rubocop-performance (~> 1.6.0)
157
+ standard (0.5.2)
158
+ rubocop (~> 0.89.1)
159
+ rubocop-performance (~> 1.7.1)
160
160
  standardrb (1.0.0)
161
161
  standard
162
162
  thor (1.0.1)
data/README.md CHANGED
@@ -44,45 +44,51 @@
44
44
  <br />
45
45
 
46
46
 
47
- ### 🎉 **You just discovered an exciting new way to build modern, reactive, real-time apps with Ruby on Rails.**
47
+ ### 🎉 **An exciting new way to build modern, reactive, real-time apps with Ruby on Rails.**
48
48
 
49
49
  StimulusReflex eliminates the complexity imposed by full-stack frontend frameworks.
50
50
  And, it's fast.
51
51
 
52
52
  It works seamlessly with the Rails tooling you already know and love.
53
53
 
54
- - [Server rendered HTML over the wire](https://guides.rubyonrails.org/action_view_overview.html)
55
- - [ERB, or your favorite templating engine](https://www.ruby-toolbox.com/categories/template_engines)
56
- - [Russian doll caching](https://edgeguides.rubyonrails.org/caching_with_rails.html#russian-doll-caching)
57
- - [Stimulus](https://stimulusjs.org/)
58
- - [Turbolinks](https://www.youtube.com/watch?v=SWEts0rlezA)
59
- - etc...
54
+ - Server-rendered HTML, delivered in miliseconds over the wire via Websockets
55
+ - ERB templates and partials, with first-class [ViewComponent](https://github.com/github/view_component) support
56
+ - [Russian doll caching](https://edgeguides.rubyonrails.org/caching_with_rails.html#russian-doll-caching) and [ActiveJob](https://guides.rubyonrails.org/active_job_basics.html)
57
+ - [StimulusJS](https://stimulusjs.org/) and [Turbolinks](https://www.youtube.com/watch?v=SWEts0rlezA)
58
+ - Built with [CableReady](https://www.youtube.com/watch?v=dPzv2qsj5L8), our secret power-move
60
59
 
61
- **The goal is to help small teams do big things with familiar tools.**
60
+ **Our goal is to help small teams do big things with familiar tools.**
62
61
 
63
62
  This project strives to live up to the vision outlined in [The Rails Doctrine](https://rubyonrails.org/doctrine/).
64
63
 
65
64
  ## 📚 Docs
66
65
 
67
- - [Official Documentation](https://docs.stimulusreflex.com)
66
+ - [StimulusReflex Documentation](https://docs.stimulusreflex.com)
67
+ - [CableReady Documentation](https://cableready.stimulusreflex.com)
68
68
 
69
69
  ## ✨ Demos
70
70
 
71
- - https://youtu.be/F5hA79vKE_E
72
- - http://expo.stimulusreflex.com
71
+ - [StimulusReflex Expo](http://expo.stimulusreflex.com) - part showcase, part learning tool
72
+ - [Build a Twitter Clone in 10 Minutes](https://youtu.be/F5hA79vKE_E) (video)
73
+ - [BoxDrop](https://dropbox-clone-rails.herokuapp.com/) - a Dropbox-inspired [concept demo](https://github.com/marcoroth/boxdrop/)
73
74
 
74
- ## 💙 Community
75
+ ## 👩‍👩‍👧 Discord Community
75
76
 
76
- - [Discourse](https://stimulus-reflex.discourse.group) - long form async communication
77
- - [Discord](https://discord.gg/XveN625) - chat root
77
+ Please join over 350 of us on [Discord](https://discord.gg/XveN625) for support getting started, as well as active discussions around Rails, StimulusJS and CableReady.
78
78
 
79
- ## 🚀 Install
79
+ ![](https://img.shields.io/discord/629472241427415060)
80
+
81
+ Stop by #newcomers and introduce yourselves!
82
+
83
+ ## 💙 Support
80
84
 
81
- ```sh
82
- bundle add stimulus_reflex && yarn add stimulus_reflex
83
- ```
85
+ Your best bet is to ask for help on Discord before filing an issue on Github. We are happy to help, and we ask people to come with all relevant code to look at. A git repo is preferred, but Gists or posts on [Discourse](https://stimulus-reflex.discourse.group) are fine, too.
86
+
87
+ Please note that we are not actively providing support on Stack Overflow. If you post there, we likely won't see it.
88
+
89
+ ## 🚀 Install
84
90
 
85
- Checkout the [documentation](https://docs.stimulusreflex.com) to continue!
91
+ CLI and manual setup procedures are fully detailed in the [official docs](https://docs.stimulusreflex.com/setup).
86
92
 
87
93
  ## 🙏 Contributing
88
94
 
@@ -32,9 +32,15 @@ class StimulusReflex::Channel < ActionCable::Channel::Base
32
32
  reflex = reflex_class.new(self, url: url, element: element, selectors: selectors, method_name: method_name, permanent_attribute_name: permanent_attribute_name, params: params)
33
33
  delegate_call_to_reflex reflex, method_name, arguments
34
34
  rescue => invoke_error
35
- reflex&.rescue_with_handler(invoke_error)
36
35
  message = exception_message_with_backtrace(invoke_error)
37
- return reflex.broadcast_message subject: "error", body: "StimulusReflex::Channel Failed to invoke #{target}! #{url} #{message}", data: data
36
+ body = "StimulusReflex::Channel Failed to invoke #{target}! #{url} #{message}"
37
+ if reflex
38
+ reflex.rescue_with_handler(invoke_error)
39
+ reflex.broadcast_message subject: "error", body: body, data: data
40
+ else
41
+ logger.error "\e[31m#{body}\e[0m"
42
+ end
43
+ return
38
44
  end
39
45
 
40
46
  if reflex.halted?
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module StimulusReflex
4
- VERSION = "3.3.0.pre2"
4
+ VERSION = "3.3.0.pre3"
5
5
  end
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- class DemoReflex < ApplicationReflex
3
+ class UserReflex < ApplicationReflex
4
4
  # Add Reflex methods in this file.
5
5
  #
6
6
  # All Reflex instances expose the following properties:
@@ -22,4 +22,12 @@ class DemoReflex < ApplicationReflex
22
22
  #
23
23
  # Learn more at: https://docs.stimulusreflex.com
24
24
 
25
+ def update
26
+ end
27
+
28
+ def do_stuff
29
+ end
30
+
31
+ def do_more_stuff
32
+ end
25
33
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stimulus_reflex
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.3.0.pre2
4
+ version: 3.3.0.pre3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathan Hopkins
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-07-17 00:00:00.000000000 Z
11
+ date: 2020-08-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rack
@@ -176,7 +176,7 @@ files:
176
176
  - test/generators/stimulus_reflex_generator_test.rb
177
177
  - test/test_helper.rb
178
178
  - test/tmp/app/reflexes/application_reflex.rb
179
- - test/tmp/app/reflexes/demo_reflex.rb
179
+ - test/tmp/app/reflexes/user_reflex.rb
180
180
  homepage: https://github.com/hopsoft/stimulus_reflex
181
181
  licenses:
182
182
  - MIT
@@ -212,5 +212,5 @@ summary: Build reactive applications with the Rails tooling you already know and
212
212
  test_files:
213
213
  - test/test_helper.rb
214
214
  - test/generators/stimulus_reflex_generator_test.rb
215
- - test/tmp/app/reflexes/demo_reflex.rb
216
215
  - test/tmp/app/reflexes/application_reflex.rb
216
+ - test/tmp/app/reflexes/user_reflex.rb