draftjs_exporter 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 61ee95a90f71865abb4072666f015cd2ef60faef
4
+ data.tar.gz: 2c2ceb50a8612074054451c544eeecd771724cb6
5
+ SHA512:
6
+ metadata.gz: 10c7d1527d1bfd2d007fe3c213385ddc25c434e15aa8d03dba858bd74c0bf0ecad31306f7689cd8f730d81768f21f75e5d5b500bc7fd2ab30567eb172d5e7224
7
+ data.tar.gz: 46056dde84ff7b0c09949f1eeb2a4e839fb49c4c3f083cd2037071738eb1b175f4390b9ec022540f31c88eafde69eed79e322271b554c9ee6e3f16712792b9be
@@ -0,0 +1,7 @@
1
+ Copyright (c) 2016 Ignition Works Limited
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4
+
5
+ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
6
+
7
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,87 @@
1
+ # Draft.js Exporter
2
+
3
+ [![Circle CI](https://circleci.com/gh/ignitionworks/draftjs_exporter/tree/master.svg?style=shield)](https://circleci.com/gh/ignitionworks/draftjs_exporter/tree/master)
4
+ [![Code Climate](https://codeclimate.com/github/ignitionworks/draftjs_exporter/badges/gpa.svg)](https://codeclimate.com/github/ignitionworks/draftjs_exporter)
5
+ [![Test Coverage](https://codeclimate.com/github/ignitionworks/draftjs_exporter/badges/coverage.svg)](https://codeclimate.com/github/ignitionworks/draftjs_exporter/coverage)
6
+
7
+ [Draft.js](https://facebook.github.io/draft-js/) is a framework for
8
+ building rich text editors. However, it does not support exporting
9
+ documents at HTML. This gem is designed to take the raw `ContentState`
10
+ (output of [`convertToRaw`](https://facebook.github.io/draft-js/docs/api-reference-data-conversion.html#converttoraw))
11
+ from Draft.js and convert it to HTML using Ruby.
12
+
13
+ ## Usage
14
+
15
+ ```ruby
16
+ # Create configuration for entities and styles
17
+ config = {
18
+ entity_decorators: {
19
+ 'LINK' => DraftjsExporter::Entities::Link.new
20
+ },
21
+ block_map: {
22
+ 'header-one' => { element: 'h1' },
23
+ 'unordered-list-item' => {
24
+ element: 'li',
25
+ wrapper: ['ul', { className: 'public-DraftStyleDefault-ul' }]
26
+ },
27
+ 'unstyled' => { element: 'div' }
28
+ },
29
+ style_map: {
30
+ 'ITALIC' => { fontStyle: 'italic' }
31
+ }
32
+ }
33
+
34
+ # New up the exporter
35
+ exporter = DraftjsExporter::HTML.new(config)
36
+
37
+ # Provide raw content state
38
+ exporter.call({
39
+ entityMap: {
40
+ '0' => {
41
+ type: 'LINK',
42
+ mutability: 'MUTABLE',
43
+ data: {
44
+ url: 'http://example.com'
45
+ }
46
+ }
47
+ },
48
+ blocks: [
49
+ {
50
+ key: '5s7g9',
51
+ text: 'Header',
52
+ type: 'header-one',
53
+ depth: 0,
54
+ inlineStyleRanges: [],
55
+ entityRanges: []
56
+ },
57
+ {
58
+ key: 'dem5p',
59
+ text: 'some paragraph text',
60
+ type: 'unstyled',
61
+ depth: 0,
62
+ inlineStyleRanges: [
63
+ {
64
+ offset: 0,
65
+ length: 4,
66
+ style: 'ITALIC'
67
+ }
68
+ ],
69
+ entityRanges: [
70
+ {
71
+ offset: 5,
72
+ length: 9,
73
+ key: 0
74
+ }
75
+ ]
76
+ }
77
+ ]
78
+ })
79
+ # => "<h1>Header</h1><div>\n<span style=\"fontStyle: italic;\">some</span> <a href=\"http://example.com\">paragraph</a> text</div>"
80
+ ```
81
+
82
+ ## Tests
83
+
84
+ ```bash
85
+ $ rspec
86
+ ```
87
+
@@ -0,0 +1,3 @@
1
+ # frozen_string_literal: true
2
+ require 'draftjs_exporter/version'
3
+ require 'draftjs_exporter/html'
@@ -0,0 +1,4 @@
1
+ # frozen_string_literal: true
2
+ module DraftjsExporter
3
+ Command = Struct.new(:name, :index, :data)
4
+ end
@@ -0,0 +1,12 @@
1
+ # frozen_string_literal: true
2
+ module DraftjsExporter
3
+ module Entities
4
+ class Link
5
+ def call(parent_element, data)
6
+ element = parent_element.document.create_element('a', href: data.fetch(:data, {}).fetch(:url))
7
+ parent_element.add_child(element)
8
+ element
9
+ end
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,10 @@
1
+ # frozen_string_literal: true
2
+ module DraftjsExporter
3
+ module Entities
4
+ class Null
5
+ def call(parent_element, _data)
6
+ parent_element
7
+ end
8
+ end
9
+ end
10
+ end
@@ -0,0 +1,49 @@
1
+ # frozen_string_literal: true
2
+ require 'draftjs_exporter/entities/null'
3
+
4
+ module DraftjsExporter
5
+ class EntityState
6
+ attr_reader :entity_decorators, :entity_map, :entity_stack, :root_element
7
+
8
+ def initialize(root_element, entity_decorators, entity_map)
9
+ @entity_decorators = entity_decorators
10
+ @entity_map = entity_map
11
+ @entity_stack = [[Entities::Null.new.call(root_element, nil), nil]]
12
+ end
13
+
14
+ def apply(command)
15
+ case command.name
16
+ when :start_entity
17
+ start_command(command)
18
+ when :stop_entity
19
+ stop_command(command)
20
+ end
21
+ end
22
+
23
+ def current_parent
24
+ element, _data = entity_stack.last
25
+ element
26
+ end
27
+
28
+ private
29
+
30
+ def start_command(command)
31
+ entity_details = entity_map.fetch(command.data.to_s)
32
+ decorator = entity_decorators.fetch(entity_details.fetch(:type))
33
+ parent_element = entity_stack.last.first
34
+ new_element = decorator.call(parent_element, entity_details)
35
+ entity_stack.push([new_element, entity_details])
36
+ end
37
+
38
+ def stop_command(command)
39
+ entity_details = entity_map.fetch(command.data.to_s)
40
+ _element, expected_entity_details = entity_stack.last
41
+
42
+ if expected_entity_details != entity_details
43
+ raise "Invalid entity. Expected #{expected_entity_details.inspect} got #{entity_details.inspect}"
44
+ end
45
+
46
+ entity_stack.pop
47
+ end
48
+ end
49
+ end
@@ -0,0 +1,102 @@
1
+ # frozen_string_literal: true
2
+ require 'nokogiri'
3
+ require 'draftjs_exporter/entity_state'
4
+ require 'draftjs_exporter/style_state'
5
+ require 'draftjs_exporter/command'
6
+
7
+ module DraftjsExporter
8
+ class HTML
9
+ attr_reader :block_map, :style_map, :entity_decorators
10
+
11
+ def initialize(block_map:, style_map:, entity_decorators:)
12
+ @block_map = block_map
13
+ @style_map = style_map
14
+ @entity_decorators = entity_decorators
15
+ end
16
+
17
+ def call(content_state)
18
+ content_state.fetch(:blocks, []).map { |block|
19
+ content_state_block(block, content_state.fetch(:entityMap, {}))
20
+ }.inject(:+)
21
+ end
22
+
23
+ private
24
+
25
+ def content_state_block(block, entity_map)
26
+ document = Nokogiri::HTML::Document.new
27
+ fragment = Nokogiri::HTML::DocumentFragment.new(document)
28
+ type = block.fetch(:type, 'unstyled')
29
+ element = document.create_element(*block_options(type)) { |e|
30
+ block_contents(e, block, entity_map)
31
+ }
32
+ fragment.add_child(element).to_s
33
+ end
34
+
35
+ def block_contents(element, block, entity_map)
36
+ style_state = StyleState.new(style_map)
37
+ entity_state = EntityState.new(element, entity_decorators, entity_map)
38
+ build_command_groups(block).each do |text, commands|
39
+ commands.each do |command|
40
+ entity_state.apply(command)
41
+ style_state.apply(command)
42
+ end
43
+
44
+ add_node(entity_state.current_parent, text, style_state)
45
+ end
46
+ end
47
+
48
+ def block_options(type)
49
+ options = block_map.fetch(type)
50
+ return [options.fetch(:element)] unless options.key?(:wrapper)
51
+
52
+ wrapper = options.fetch(:wrapper)
53
+ name = wrapper[0]
54
+ config = wrapper[1] || {}
55
+ options = {}
56
+ options[:class] = config.fetch(:className) if config.key?(:className)
57
+ [name, options]
58
+ end
59
+
60
+ def add_node(element, text, state)
61
+ document = element.document
62
+ node = if state.text?
63
+ document.create_text_node(text)
64
+ else
65
+ document.create_element('span', text, state.element_attributes)
66
+ end
67
+ element.add_child(node)
68
+ end
69
+
70
+ def build_command_groups(block)
71
+ text = block.fetch(:text)
72
+ grouped = build_commands(block).group_by(&:index).sort
73
+ grouped.map.with_index { |(index, commands), command_index|
74
+ start_index = index
75
+ next_group = grouped[command_index + 1]
76
+ stop_index = (next_group && next_group.first || 0) - 1
77
+ [text.slice(start_index..stop_index), commands]
78
+ }
79
+ end
80
+
81
+ def build_commands(block)
82
+ [
83
+ Command.new(:start_text, 0),
84
+ Command.new(:stop_text, block.fetch(:text).size)
85
+ ] +
86
+ build_range_commands(:inline_style, :style, block.fetch(:inlineStyleRanges)) +
87
+ build_range_commands(:entity, :key, block.fetch(:entityRanges))
88
+ end
89
+
90
+ def build_range_commands(name, data_key, ranges)
91
+ ranges.flat_map { |range|
92
+ data = range.fetch(data_key)
93
+ start = range.fetch(:offset)
94
+ stop = start + range.fetch(:length)
95
+ [
96
+ Command.new("start_#{name}".to_sym, start, data),
97
+ Command.new("stop_#{name}".to_sym, stop, data)
98
+ ]
99
+ }
100
+ end
101
+ end
102
+ end
@@ -0,0 +1,37 @@
1
+ # frozen_string_literal: true
2
+ module DraftjsExporter
3
+ class StyleState
4
+ attr_reader :styles, :style_map
5
+
6
+ def initialize(style_map)
7
+ @styles = []
8
+ @style_map = style_map
9
+ end
10
+
11
+ def apply(command)
12
+ case command.name
13
+ when :start_inline_style
14
+ styles.push(command.data)
15
+ when :stop_inline_style
16
+ styles.delete(command.data)
17
+ end
18
+ end
19
+
20
+ def text?
21
+ styles.empty?
22
+ end
23
+
24
+ def element_attributes
25
+ return {} unless styles.any?
26
+ { style: styles_css }
27
+ end
28
+
29
+ def styles_css
30
+ styles.map { |style|
31
+ style_map.fetch(style)
32
+ }.inject({}, :merge).map { |key, value|
33
+ "#{key}: #{value};"
34
+ }.join
35
+ end
36
+ end
37
+ end
@@ -0,0 +1,4 @@
1
+ # frozen_string_literal: true
2
+ module DraftjsExporter
3
+ VERSION = '0.0.1'.freeze
4
+ end
@@ -0,0 +1,78 @@
1
+ # frozen_string_literal: true
2
+ require 'spec_helper'
3
+ require 'draftjs_exporter/html'
4
+ require 'draftjs_exporter/entities/link'
5
+
6
+ RSpec.describe DraftjsExporter::HTML do
7
+ subject(:mapper) do
8
+ described_class.new(
9
+ entity_decorators: {
10
+ 'LINK' => DraftjsExporter::Entities::Link.new
11
+ },
12
+ block_map: {
13
+ 'header-one' => { element: 'h1' },
14
+ 'unordered-list-item' => {
15
+ element: 'li',
16
+ wrapper: ['ul', { className: 'public-DraftStyleDefault-ul' }]
17
+ },
18
+ 'unstyled' => { element: 'div' }
19
+ },
20
+ style_map: {
21
+ 'ITALIC' => { fontStyle: 'italic' }
22
+ }
23
+ )
24
+ end
25
+
26
+ describe '#call' do
27
+ it 'decodes the content_state to html' do
28
+ input = {
29
+ entityMap: {
30
+ '0' => {
31
+ type: 'LINK',
32
+ mutability: 'MUTABLE',
33
+ data: {
34
+ url: 'http://example.com'
35
+ }
36
+ }
37
+ },
38
+ blocks: [
39
+ {
40
+ key: '5s7g9',
41
+ text: 'Header',
42
+ type: 'header-one',
43
+ depth: 0,
44
+ inlineStyleRanges: [],
45
+ entityRanges: []
46
+ },
47
+ {
48
+ key: 'dem5p',
49
+ text: 'some paragraph text',
50
+ type: 'unstyled',
51
+ depth: 0,
52
+ inlineStyleRanges: [
53
+ {
54
+ offset: 0,
55
+ length: 4,
56
+ style: 'ITALIC'
57
+ }
58
+ ],
59
+ entityRanges: [
60
+ {
61
+ offset: 5,
62
+ length: 9,
63
+ key: 0
64
+ }
65
+ ]
66
+ }
67
+ ]
68
+ }
69
+
70
+ expected_output = <<-OUTPUT.strip
71
+ <h1>Header</h1><div>
72
+ <span style="fontStyle: italic;">some</span> <a href="http://example.com">paragraph</a> text</div>
73
+ OUTPUT
74
+
75
+ expect(mapper.call(input)).to eq(expected_output)
76
+ end
77
+ end
78
+ end
@@ -0,0 +1,13 @@
1
+ RSpec.describe 'requires' do
2
+ describe 'draftjs_exporter' do
3
+ it 'can be required' do
4
+ expect { require('draftjs_exporter') }.to_not raise_error
5
+ end
6
+ end
7
+
8
+ describe 'draftjs_exporter/version' do
9
+ it 'can be required' do
10
+ expect { require('draftjs_exporter/version') }.to_not raise_error
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,25 @@
1
+ # frozen_string_literal: true
2
+ require 'simplecov'
3
+ require 'codeclimate-test-reporter'
4
+
5
+ SimpleCov.start do
6
+ formatter SimpleCov::Formatter::MultiFormatter.new(
7
+ [
8
+ SimpleCov::Formatter::HTMLFormatter,
9
+ CodeClimate::TestReporter::Formatter
10
+ ]
11
+ )
12
+ end
13
+
14
+ RSpec.configure do |config|
15
+ config.expect_with :rspec do |expectations|
16
+ expectations.include_chain_clauses_in_custom_matcher_descriptions = true
17
+ end
18
+
19
+ config.mock_with :rspec do |mocks|
20
+ mocks.verify_partial_doubles = true
21
+ end
22
+
23
+ config.disable_monkey_patching!
24
+ config.order = :random
25
+ end
metadata ADDED
@@ -0,0 +1,243 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: draftjs_exporter
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Theo Cushion
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2016-06-21 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: nokogiri
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.6'
20
+ - - ">="
21
+ - !ruby/object:Gem::Version
22
+ version: 1.6.0
23
+ type: :runtime
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - "~>"
28
+ - !ruby/object:Gem::Version
29
+ version: '1.6'
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: 1.6.0
33
+ - !ruby/object:Gem::Dependency
34
+ name: rspec
35
+ requirement: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - "~>"
38
+ - !ruby/object:Gem::Version
39
+ version: '3.4'
40
+ - - ">="
41
+ - !ruby/object:Gem::Version
42
+ version: 3.4.0
43
+ type: :development
44
+ prerelease: false
45
+ version_requirements: !ruby/object:Gem::Requirement
46
+ requirements:
47
+ - - "~>"
48
+ - !ruby/object:Gem::Version
49
+ version: '3.4'
50
+ - - ">="
51
+ - !ruby/object:Gem::Version
52
+ version: 3.4.0
53
+ - !ruby/object:Gem::Dependency
54
+ name: rubocop
55
+ requirement: !ruby/object:Gem::Requirement
56
+ requirements:
57
+ - - "~>"
58
+ - !ruby/object:Gem::Version
59
+ version: '0.40'
60
+ - - ">="
61
+ - !ruby/object:Gem::Version
62
+ version: 0.40.0
63
+ type: :development
64
+ prerelease: false
65
+ version_requirements: !ruby/object:Gem::Requirement
66
+ requirements:
67
+ - - "~>"
68
+ - !ruby/object:Gem::Version
69
+ version: '0.40'
70
+ - - ">="
71
+ - !ruby/object:Gem::Version
72
+ version: 0.40.0
73
+ - !ruby/object:Gem::Dependency
74
+ name: codeclimate-test-reporter
75
+ requirement: !ruby/object:Gem::Requirement
76
+ requirements:
77
+ - - "~>"
78
+ - !ruby/object:Gem::Version
79
+ version: '0.5'
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: 0.5.0
83
+ type: :development
84
+ prerelease: false
85
+ version_requirements: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - "~>"
88
+ - !ruby/object:Gem::Version
89
+ version: '0.5'
90
+ - - ">="
91
+ - !ruby/object:Gem::Version
92
+ version: 0.5.0
93
+ - !ruby/object:Gem::Dependency
94
+ name: simplecov
95
+ requirement: !ruby/object:Gem::Requirement
96
+ requirements:
97
+ - - "~>"
98
+ - !ruby/object:Gem::Version
99
+ version: '0.11'
100
+ - - ">="
101
+ - !ruby/object:Gem::Version
102
+ version: 0.11.0
103
+ type: :development
104
+ prerelease: false
105
+ version_requirements: !ruby/object:Gem::Requirement
106
+ requirements:
107
+ - - "~>"
108
+ - !ruby/object:Gem::Version
109
+ version: '0.11'
110
+ - - ">="
111
+ - !ruby/object:Gem::Version
112
+ version: 0.11.0
113
+ description: |+
114
+ # Draft.js Exporter
115
+
116
+ [![Circle CI](https://circleci.com/gh/ignitionworks/draftjs_exporter/tree/master.svg?style=shield)](https://circleci.com/gh/ignitionworks/draftjs_exporter/tree/master)
117
+ [![Code Climate](https://codeclimate.com/github/ignitionworks/draftjs_exporter/badges/gpa.svg)](https://codeclimate.com/github/ignitionworks/draftjs_exporter)
118
+ [![Test Coverage](https://codeclimate.com/github/ignitionworks/draftjs_exporter/badges/coverage.svg)](https://codeclimate.com/github/ignitionworks/draftjs_exporter/coverage)
119
+
120
+ [Draft.js](https://facebook.github.io/draft-js/) is a framework for
121
+ building rich text editors. However, it does not support exporting
122
+ documents at HTML. This gem is designed to take the raw `ContentState`
123
+ (output of [`convertToRaw`](https://facebook.github.io/draft-js/docs/api-reference-data-conversion.html#converttoraw))
124
+ from Draft.js and convert it to HTML using Ruby.
125
+
126
+ ## Usage
127
+
128
+ ```ruby
129
+ # Create configuration for entities and styles
130
+ config = {
131
+ entity_decorators: {
132
+ 'LINK' => DraftjsExporter::Entities::Link.new
133
+ },
134
+ block_map: {
135
+ 'header-one' => { element: 'h1' },
136
+ 'unordered-list-item' => {
137
+ element: 'li',
138
+ wrapper: ['ul', { className: 'public-DraftStyleDefault-ul' }]
139
+ },
140
+ 'unstyled' => { element: 'div' }
141
+ },
142
+ style_map: {
143
+ 'ITALIC' => { fontStyle: 'italic' }
144
+ }
145
+ }
146
+
147
+ # New up the exporter
148
+ exporter = DraftjsExporter::HTML.new(config)
149
+
150
+ # Provide raw content state
151
+ exporter.call({
152
+ entityMap: {
153
+ '0' => {
154
+ type: 'LINK',
155
+ mutability: 'MUTABLE',
156
+ data: {
157
+ url: 'http://example.com'
158
+ }
159
+ }
160
+ },
161
+ blocks: [
162
+ {
163
+ key: '5s7g9',
164
+ text: 'Header',
165
+ type: 'header-one',
166
+ depth: 0,
167
+ inlineStyleRanges: [],
168
+ entityRanges: []
169
+ },
170
+ {
171
+ key: 'dem5p',
172
+ text: 'some paragraph text',
173
+ type: 'unstyled',
174
+ depth: 0,
175
+ inlineStyleRanges: [
176
+ {
177
+ offset: 0,
178
+ length: 4,
179
+ style: 'ITALIC'
180
+ }
181
+ ],
182
+ entityRanges: [
183
+ {
184
+ offset: 5,
185
+ length: 9,
186
+ key: 0
187
+ }
188
+ ]
189
+ }
190
+ ]
191
+ })
192
+ # => "<h1>Header</h1><div>\n<span style=\"fontStyle: italic;\">some</span> <a href=\"http://example.com\">paragraph</a> text</div>"
193
+ ```
194
+
195
+ ## Tests
196
+
197
+ ```bash
198
+ $ rspec
199
+ ```
200
+
201
+ email: theo@ignition.works
202
+ executables: []
203
+ extensions: []
204
+ extra_rdoc_files: []
205
+ files:
206
+ - LICENSE.md
207
+ - README.md
208
+ - lib/draftjs_exporter.rb
209
+ - lib/draftjs_exporter/command.rb
210
+ - lib/draftjs_exporter/entities/link.rb
211
+ - lib/draftjs_exporter/entities/null.rb
212
+ - lib/draftjs_exporter/entity_state.rb
213
+ - lib/draftjs_exporter/html.rb
214
+ - lib/draftjs_exporter/style_state.rb
215
+ - lib/draftjs_exporter/version.rb
216
+ - spec/integrations/html_spec.rb
217
+ - spec/integrations/requires_spec.rb
218
+ - spec/spec_helper.rb
219
+ homepage: https://github.com/ignitionworks/draftjs_exporter
220
+ licenses:
221
+ - MIT
222
+ metadata: {}
223
+ post_install_message:
224
+ rdoc_options: []
225
+ require_paths:
226
+ - lib
227
+ required_ruby_version: !ruby/object:Gem::Requirement
228
+ requirements:
229
+ - - ">="
230
+ - !ruby/object:Gem::Version
231
+ version: 2.1.0
232
+ required_rubygems_version: !ruby/object:Gem::Requirement
233
+ requirements:
234
+ - - ">="
235
+ - !ruby/object:Gem::Version
236
+ version: '0'
237
+ requirements: []
238
+ rubyforge_project:
239
+ rubygems_version: 2.5.1
240
+ signing_key:
241
+ specification_version: 4
242
+ summary: Export Draft.js content state into HTML
243
+ test_files: []