futurism 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -2
- data/lib/futurism/helpers.rb +1 -1
- data/lib/futurism/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 54844ecdb7da8a4fe22cc7635a9b7eba3a5a6ffe29a68c8f5a12f9aae0f616da
|
4
|
+
data.tar.gz: 1b4e6c2d0ae11095ae535e1248e72af66dd030c9e3bb3b7d8fbda47cb204eccb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 47de6e6462abad9b682b01297cf3ee76ba7b4111f41afd8c8d81baa9b3d36b5be02c548e2421150437f84cbab8644d2766e976fa836490ca37a57b6497536f18
|
7
|
+
data.tar.gz: a1c145a00972f4ed088bfc1283a2e1bd133dc59828740be0bf6a599968a914fcbf1771d25747265166b1c193e801029490d981a7baf29e0041948402f372430b
|
data/README.md
CHANGED
@@ -8,14 +8,14 @@ with a helper in your template
|
|
8
8
|
<%= futurize @posts %>
|
9
9
|
```
|
10
10
|
|
11
|
-
custom `<futurism-elements>` (in the form of a `<div>` or a `<tr is="futurism-table-row">` are rendered. Those custom elements have an `IntersectionObserver` attached that will send
|
11
|
+
custom `<futurism-elements>` (in the form of a `<div>` or a `<tr is="futurism-table-row">` are rendered. Those custom elements have an `IntersectionObserver` attached that will send a signed global id to an ActionCable channel (`FuturismChannel`) which will then replace the placeholders with the actual resource partial.
|
12
12
|
|
13
13
|
With that method, you could lazy load every class that has to_partial_path defined (ActiveModel has by default).
|
14
14
|
|
15
15
|
You can pass the placeholder as a block:
|
16
16
|
|
17
17
|
```erb
|
18
|
-
<%= futurize @posts do %>
|
18
|
+
<%= futurize @posts, extends: :tr do %>
|
19
19
|
<td class="placeholder"></td>
|
20
20
|
<% end %>
|
21
21
|
```
|
data/lib/futurism/helpers.rb
CHANGED
data/lib/futurism/version.rb
CHANGED