readability_js 0.0.3 → 0.0.5

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c536792a9e26ab4080c31b6065e02fab9a5ed5536993eeac15e53b0fd1c288fc
4
- data.tar.gz: 88baef9c54969ca53e2bef99550d9da1445b72b62d8da43250d564c0ed1bc3e5
3
+ metadata.gz: 9a5faf9c156d80158ba2ee471bb3d7ec102396c3c03ca5472162211706ac74d9
4
+ data.tar.gz: 16a0a329c137ecfbae089501b24f4dea0cc00395d62d5bedc123c40757018e27
5
5
  SHA512:
6
- metadata.gz: 552063ebef5709acb6ca6a9744bf69e8c33499d24d0b9db7d5bcaef53a3429f0b72b7bc7f12350d2e0137ef20c5603489feb731de831044cb2f1cda742168d75
7
- data.tar.gz: 11b0a652f07d3c722775a7f9fc401af4e20ee2abb8513e60bba44a7b5a1e0e8d9df0bf7477f8e5aa0fdfc1c147186094a610e0aea02757a70f2752845f241265
6
+ metadata.gz: 0f3b5aa2bb14ee235f3aad9b884cdeeb801e28ea18048d33d7a2c50921e89b33210df375e7d67607f86c33c23a0c1cfa3b82fd8420951ea5008534164eede0a8
7
+ data.tar.gz: ae1fe7c1decc638e7da359f16c8178a6ce8f02a2632bef7b5e3e4542bc7de17b52bba16bce4dbb70692a4db87c46728c1943f13b6134c5a0b101d458fc7baf78
data/CHANGELOG.md CHANGED
@@ -1,2 +1,8 @@
1
+ ## 0.0.4
2
+ * Do not add image_url to text_content result.
3
+
4
+ ## 0.0.3
5
+ * Finally finished complete implementation of `isProbablyReaderable` including visibility function parameter.
6
+
1
7
  ## 0.0.1
2
8
  * Initial release with basic wrapper
data/README.md CHANGED
@@ -69,7 +69,7 @@ and includes a beautified markdown version of the content.
69
69
  ```
70
70
 
71
71
  ### Query parameters
72
- You can pass all parameters supported by readability, checkout the [rubydoc for more details](https://www.rubydoc.info/gems/readability_js/ReadabilityJs).
72
+ You can pass all parameters supported by readability, checkout the [rubydoc for more details](https://rubydoc.info/github/magynhard/ruby-readability_js/ReadabilityJs).
73
73
 
74
74
  Here an example with all parameters, the camelCase parameters are converted to snake_case in ruby:
75
75
 
@@ -105,7 +105,7 @@ It contains the data returned by readability, with hash keys transformed in snak
105
105
  <a name="documentation"></a>
106
106
  ## Documentation
107
107
  Check out the doc at RubyDoc:<br>
108
- https://www.rubydoc.info/gems/readability_js
108
+ https://rubydoc.info/github/magynhard/ruby-readability_js
109
109
 
110
110
 
111
111
  As this library is only a wrapper, checkout the original readability documentation:<br>
@@ -148,7 +148,7 @@ module ReadabilityJs
148
148
  # @return [String] The cleaned HTML content as a string.
149
149
  #
150
150
  def self.clean_up_comments(html)
151
- copy = html.dup
151
+ copy = html.dup.to_s
152
152
  # Turn \x3C before comment start into '<'
153
153
  copy.gsub!(/\\x3C(?=!--)/, '<')
154
154
  # Decode encoded comment end --&gt; to -->
@@ -242,7 +242,6 @@ module ReadabilityJs
242
242
  if h1
243
243
  h1.add_next_sibling(Nokogiri::HTML::DocumentFragment.parse(img_tag))
244
244
  html = doc.to_html
245
- text = result['image_url'] + "\n\n" + text
246
245
  end
247
246
  end
248
247
  end
@@ -1,3 +1,3 @@
1
1
  module ReadabilityJs
2
- VERSION = '0.0.3'.freeze
2
+ VERSION = '0.0.5'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: readability_js
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matthäus Beyrle