slim-rails 3.6.1 → 3.6.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +14 -0
- data/README.md +10 -6
- data/lib/generators/slim/scaffold/templates/_form.html.slim.tt +4 -4
- data/lib/slim-rails/version.rb +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f5fb2e2fadfea78a5815dfb50846528d1805915e7f8fbc0061ba149e47ff6fdf
|
4
|
+
data.tar.gz: 0f1f0b38ae601fd5c24e498bf577c3ae10f33397d78e211e42d0429aea6a58e0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c0f6ca2288d30efa2bfc772610a99bf1815baee1f394485404767d02caaaac16928f25337e1cdd9e8182f0bfd8ba0b18cfd30c7e3492de9a4096b299d94aa97d
|
7
|
+
data.tar.gz: b7c93eb2b1176f04bb35eabf34dbb5e9088d1d5c5feb0e633c6e12b98124101261fb3de9bbe3829fe76c27b419167b1c695f897bb3dac4f9ce4ba60962853a29
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,17 @@
|
|
1
|
+
## 3.6.1 (February 14, 2023)
|
2
|
+
|
3
|
+
- Fix to avoid depending on the failed Slim 5.0.0 release ([#188])
|
4
|
+
|
5
|
+
[#188]: https://github.com/slim-template/slim-rails/pull/188
|
6
|
+
|
7
|
+
## 3.6.0 (February 14, 2023)
|
8
|
+
|
9
|
+
- Add support for Slim 5 ([#185])
|
10
|
+
|
11
|
+
Thanks https://github.com/michaelbaudino ([#185])
|
12
|
+
|
13
|
+
[#185]: https://github.com/slim-template/slim-rails/pull/185
|
14
|
+
|
1
15
|
## 3.5.0 (May 2022)
|
2
16
|
|
3
17
|
* Restored legacy templates for Rails < 7
|
data/README.md
CHANGED
@@ -1,8 +1,6 @@
|
|
1
1
|
# slim-rails [![Gem Version](https://img.shields.io/gem/v/slim-rails.svg)](http://rubygems.org/gems/slim-rails) [![Build Status](https://github.com/slim-template/slim-rails/actions/workflows/main.yml/badge.svg)](https://github.com/slim-template/slim-rails/actions/workflows/main.yml) [![Code Climate](https://codeclimate.com/github/slim-template/slim-rails/badges/gpa.svg)](https://codeclimate.com/github/slim-template/slim-rails)
|
2
2
|
|
3
|
-
slim-rails provides Slim generators for Rails
|
4
|
-
[haml-rails](http://github.com/indirect/haml-rails) and it does basically the
|
5
|
-
same:
|
3
|
+
slim-rails provides Slim generators for Rails:
|
6
4
|
|
7
5
|
* Any time you generate a controller or scaffold, you'll get Slim templates
|
8
6
|
(instead of ERB)
|
@@ -18,8 +16,14 @@ gem "slim-rails"
|
|
18
16
|
|
19
17
|
And that's it.
|
20
18
|
|
21
|
-
|
19
|
+
Every time you generate a controller or scaffold, you'll get Slim templates.
|
22
20
|
|
23
|
-
|
21
|
+
If you have existing `.erb` templates, check out our guide [How to convert your `.erb` templates to `.slim`](https://github.com/slim-template/slim/wiki/Template-Converters-ERB-to-SLIM) on how to achieve this.
|
24
22
|
|
25
|
-
|
23
|
+
This gem is [tested with Ruby on Rails 5.2+](/.github/workflows/main.yml).
|
24
|
+
|
25
|
+
## History
|
26
|
+
|
27
|
+
`slim-rails` was based on [haml-rails](https://github.com/haml/haml-rails) and it does basically the same thing.
|
28
|
+
|
29
|
+
From the version 0.2.0, there is no need to include gem "slim" in your Gemfile.
|
@@ -1,9 +1,9 @@
|
|
1
|
-
= form_with(model:
|
2
|
-
- if
|
1
|
+
= form_with(model: <%= model_resource_name %>) do |form|
|
2
|
+
- if <%= singular_table_name %>.errors.any?
|
3
3
|
div style="color: red"
|
4
|
-
h2 = "#{pluralize(
|
4
|
+
h2 = "#{pluralize(<%= singular_table_name %>.errors.count, "error")} prohibited this <%= singular_table_name %> from being saved:"
|
5
5
|
ul
|
6
|
-
-
|
6
|
+
- <%= singular_table_name %>.errors.each do |error|
|
7
7
|
li = error.full_message
|
8
8
|
|
9
9
|
<% attributes.each do |attribute| -%>
|
data/lib/slim-rails/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: slim-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.6.
|
4
|
+
version: 3.6.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Leonardo Almeida
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2023-
|
12
|
+
date: 2023-10-24 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: actionpack
|
@@ -85,14 +85,14 @@ dependencies:
|
|
85
85
|
requirements:
|
86
86
|
- - "~>"
|
87
87
|
- !ruby/object:Gem::Version
|
88
|
-
version: 0.
|
88
|
+
version: 0.24.0
|
89
89
|
type: :development
|
90
90
|
prerelease: false
|
91
91
|
version_requirements: !ruby/object:Gem::Requirement
|
92
92
|
requirements:
|
93
93
|
- - "~>"
|
94
94
|
- !ruby/object:Gem::Version
|
95
|
-
version: 0.
|
95
|
+
version: 0.24.0
|
96
96
|
- !ruby/object:Gem::Dependency
|
97
97
|
name: rocco
|
98
98
|
requirement: !ruby/object:Gem::Requirement
|
@@ -229,7 +229,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
229
229
|
- !ruby/object:Gem::Version
|
230
230
|
version: '0'
|
231
231
|
requirements: []
|
232
|
-
rubygems_version: 3.
|
232
|
+
rubygems_version: 3.4.10
|
233
233
|
signing_key:
|
234
234
|
specification_version: 4
|
235
235
|
summary: Slim templates generator for Rails
|