turbo-rails 1.1.1 → 1.4.0
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 +4 -4
- data/README.md +1 -1
- data/Rakefile +15 -2
- data/app/assets/javascripts/turbo.js +1214 -561
- data/app/assets/javascripts/turbo.min.js +6 -6
- data/app/assets/javascripts/turbo.min.js.map +1 -1
- data/app/channels/turbo/streams/broadcasts.rb +1 -1
- data/app/controllers/turbo/frames/frame_request.rb +15 -7
- data/app/controllers/turbo/native/navigation.rb +3 -1
- data/app/helpers/turbo/drive_helper.rb +16 -3
- data/app/helpers/turbo/streams/action_helper.rb +8 -6
- data/app/javascript/turbo/cable_stream_source_element.js +17 -2
- data/app/javascript/turbo/fetch_requests.js +50 -0
- data/app/javascript/turbo/index.js +3 -2
- data/app/models/concerns/turbo/broadcastable.rb +29 -10
- data/app/models/turbo/streams/tag_builder.rb +2 -0
- data/app/views/layouts/turbo_rails/frame.html.erb +8 -0
- data/lib/turbo/version.rb +1 -1
- metadata +5 -4
- data/app/javascript/turbo/form_submissions.js +0 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 40ccdc123db34929af83c559e6bf6c65ca3027b5fd765546143f6093d34662a7
|
4
|
+
data.tar.gz: 7236691e0dbf00c61fb51039212c9316b7d0fc5d03370e939c5c318b56ab70c7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e7b6bdb711d3e712ac96bd52fc6f909d2ea5beaa2ba664d10e4678792afc58bb61ecce45ccb9b745e8f3706e5221917c754c2a461caff4be864e294050aba10d
|
7
|
+
data.tar.gz: a6d86dc5249f31161e4f7c3e31cfcda725b1173f0c63348c81f0cd62135688408b4b963540f80564d5eec1fb86f7601090e24c00ed5a55fa5e9c5277a18d75a4
|
data/README.md
CHANGED
@@ -32,7 +32,7 @@ Turbo reinvents the old HTML technique of frames without any of the drawbacks th
|
|
32
32
|
|
33
33
|
It also makes it dead easy to carve a single page into smaller pieces that can all live on their own cache timeline. While the bulk of the page might easily be cached between users, a small personalized toolbar perhaps cannot. With Turbo::Frames, you can designate the toolbar as a frame, which will be **lazy-loaded automatically** by the publicly-cached root page. This means simpler pages, easier caching schemes with fewer dependent keys, and all without needing to write a lick of custom JavaScript.
|
34
34
|
|
35
|
-
This gem provides a `turbo_frame_tag` helper to create those
|
35
|
+
This gem provides a `turbo_frame_tag` helper to create those frames.
|
36
36
|
|
37
37
|
For instance:
|
38
38
|
```erb
|
data/Rakefile
CHANGED
@@ -9,7 +9,20 @@ load "rails/tasks/statistics.rake"
|
|
9
9
|
Rake::TestTask.new do |test|
|
10
10
|
test.libs << "test"
|
11
11
|
test.test_files = FileList["test/**/*_test.rb"]
|
12
|
-
test.warning = false
|
13
12
|
end
|
14
13
|
|
15
|
-
task
|
14
|
+
task :test_prereq do
|
15
|
+
puts "Installing Ruby dependencies"
|
16
|
+
`bundle install`
|
17
|
+
|
18
|
+
puts "Installing JavaScript dependencies"
|
19
|
+
`yarn install`
|
20
|
+
|
21
|
+
puts "Building JavaScript"
|
22
|
+
`yarn build`
|
23
|
+
|
24
|
+
puts "Preparing test database"
|
25
|
+
`cd test/dummy; ./bin/rails db:test:prepare; cd ../..`
|
26
|
+
end
|
27
|
+
|
28
|
+
task default: [:test_prereq, :test]
|