mjml-rails 2.4.3 → 4.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/README.md +14 -6
- data/lib/mjml.rb +1 -2
- data/lib/mjml/version.rb +1 -1
- metadata +3 -3
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 72a95cbc8dcf59b245446fd1406d85d1b6b043ba
|
4
|
+
data.tar.gz: 79a41fff1da9e8af8fdfecd2dd22c4a046171e6a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 77bbcb101b03a89845d1439c93ebc83322fffc70118596441141d63310e9542ece495b2eafc838fe1eac73767a5dc31d8c395fd570ab5dbd156b9662b6ca50bc
|
7
|
+
data.tar.gz: 0bc851c256341883f0e69ccc44aa2b60a228b3193ed6cf846409ae283eed27de91b4751260b54cff35b93ba8a373c18a7b619096e108cda8ac6a7dfb16cf8c06
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data.tar.gz.sig
CHANGED
Binary file
|
data/README.md
CHANGED
@@ -62,7 +62,7 @@ bundle install
|
|
62
62
|
Install the MJML parser (optional -g to install it globally):
|
63
63
|
|
64
64
|
```console
|
65
|
-
npm install -g mjml
|
65
|
+
npm install -g mjml@4.0.0
|
66
66
|
```
|
67
67
|
|
68
68
|
Note that you'll need at least Node.js version 6 for MJML to function properly.
|
@@ -76,9 +76,11 @@ Mjml.setup do |config|
|
|
76
76
|
end
|
77
77
|
```
|
78
78
|
|
79
|
-
### MJML v3.x support
|
79
|
+
### MJML v3.x & v4.0.x support
|
80
80
|
|
81
|
-
Version
|
81
|
+
Version 4.0.x of this gem brings support for MJML 4.0.x
|
82
|
+
|
83
|
+
Version 2.3.x and 2.4.x of this gem brings support for MJML 3.x
|
82
84
|
|
83
85
|
If you'd rather still stick with MJML 2.x then lock the mjml-rails gem:
|
84
86
|
|
@@ -86,6 +88,12 @@ If you'd rather still stick with MJML 2.x then lock the mjml-rails gem:
|
|
86
88
|
gem 'mjml-rails', '2.2.0'
|
87
89
|
```
|
88
90
|
|
91
|
+
For MJML 3.x lock the mjml-rails gem:
|
92
|
+
|
93
|
+
```ruby
|
94
|
+
gem 'mjml-rails', '2.4.3'
|
95
|
+
```
|
96
|
+
|
89
97
|
### How to guides
|
90
98
|
|
91
99
|
[Hugo Giraudel](https://twitter.com/hugogiraudel) wrote a post on [using MJML in Rails](http://dev.edenspiekermann.com/2016/06/02/using-mjml-in-rails/).
|
@@ -170,8 +178,8 @@ class DeviseMailer < Devise::Mailer
|
|
170
178
|
# Custom logic to send the email with MJML
|
171
179
|
mail(
|
172
180
|
template_path: 'devise/mailer',
|
173
|
-
from: "some@email.com",
|
174
|
-
to: record.email,
|
181
|
+
from: "some@email.com",
|
182
|
+
to: record.email,
|
175
183
|
subject: "Custom subject"
|
176
184
|
) do |format|
|
177
185
|
format.mjml
|
@@ -216,7 +224,7 @@ Next you'll need to setup a `package.json` file in the root, something like this
|
|
216
224
|
"test": "test"
|
217
225
|
},
|
218
226
|
"dependencies": {
|
219
|
-
"mjml": "^
|
227
|
+
"mjml": "^4.0.0",
|
220
228
|
},
|
221
229
|
"repository": {
|
222
230
|
"type": "git",
|
data/lib/mjml.rb
CHANGED
@@ -10,8 +10,7 @@ module Mjml
|
|
10
10
|
@@template_language = :erb
|
11
11
|
|
12
12
|
def self.check_version(bin)
|
13
|
-
|
14
|
-
Gem::Dependency.new('', '~> 3.0').match?('', version)
|
13
|
+
IO.popen("#{bin} --version").read.include?('mjml-core: 4.0.')
|
15
14
|
rescue
|
16
15
|
false
|
17
16
|
end
|
data/lib/mjml/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mjml-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 4.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Simon Loffler
|
@@ -31,7 +31,7 @@ cert_chain:
|
|
31
31
|
IUdCp7zF7QpeLz6cgerOpdG0NLHQOEPcWqHpt4yM++TieNrYOuJlkkSd11Ypvgsc
|
32
32
|
RRE0kJj2aO7haTBQ7uQl3cTv2c1s4bLu
|
33
33
|
-----END CERTIFICATE-----
|
34
|
-
date:
|
34
|
+
date: 2018-03-07 00:00:00.000000000 Z
|
35
35
|
dependencies: []
|
36
36
|
description: Render MJML + ERb template views in Rails
|
37
37
|
email: sighmon@sighmon.com
|
@@ -75,7 +75,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
75
75
|
version: '0'
|
76
76
|
requirements: []
|
77
77
|
rubyforge_project:
|
78
|
-
rubygems_version: 2.6.
|
78
|
+
rubygems_version: 2.6.14
|
79
79
|
signing_key:
|
80
80
|
specification_version: 4
|
81
81
|
summary: MJML + ERb templates
|
metadata.gz.sig
CHANGED
Binary file
|