fi_seo 0.1.2 → 0.1.7
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/Gemfile +1 -1
- data/Gemfile.lock +3 -3
- data/LICENSE.txt +1 -1
- data/README.md +20 -3
- data/fi_seo.gemspec +4 -4
- data/lib/acts_as_seoable/version.rb +1 -1
- data/lib/fi_seo.rb +15 -3
- metadata +12 -8
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 1ca0f8b268f3b5f9ec36b159c5417c3bad3f9fd9b51234eaba8ede722a24ce85
|
|
4
|
+
data.tar.gz: 8aee4bf82665cc6b242a6f388077e2f10433c24330c70eca93f0fa178bebe1f5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 5d8f27860c113f77eb8097ba2bf61aacd7351e5eb9869bfddd4498fbfbd51ce39b65ab00f66a654bcd58b276c2a0722cc31873234a1b2fb2ec2c29facef44d32
|
|
7
|
+
data.tar.gz: 415e0ae8f6beaab47fec4b300ff2851daae6a887d23eadc205667a95fbc1a7b87bff230da8ce52b70a07b850fce9f7673caa08edcb65c397bf8bf7c43f50e99d
|
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
fi_seo (0.1.
|
|
5
|
-
activerecord
|
|
4
|
+
fi_seo (0.1.4)
|
|
5
|
+
activerecord (>= 5.0, < 6.1)
|
|
6
6
|
meta-tags (~> 2.13)
|
|
7
7
|
xml-sitemap (~> 1.3, >= 1.3.3)
|
|
8
8
|
|
|
@@ -82,7 +82,7 @@ PLATFORMS
|
|
|
82
82
|
ruby
|
|
83
83
|
|
|
84
84
|
DEPENDENCIES
|
|
85
|
-
activerecord
|
|
85
|
+
activerecord (>= 5.0, < 6.1)
|
|
86
86
|
fi_seo!
|
|
87
87
|
meta-tags (~> 2.13)
|
|
88
88
|
rake (~> 12.0)
|
data/LICENSE.txt
CHANGED
data/README.md
CHANGED
|
@@ -125,7 +125,7 @@ If the model has attributes for that you need to use for the seoable attributes
|
|
|
125
125
|
acts_as_seoable :title_seoable, :description, :keywords
|
|
126
126
|
|
|
127
127
|
def title_seoable
|
|
128
|
-
"#{self.name}#{self.id}"
|
|
128
|
+
"#{self.name}#{self.id}"
|
|
129
129
|
end
|
|
130
130
|
```
|
|
131
131
|
when you create a new record from this model the gem will create a corresponding seoable record as well. Above values will be set as default values.
|
|
@@ -171,6 +171,23 @@ def twitter_tags
|
|
|
171
171
|
end
|
|
172
172
|
```
|
|
173
173
|
|
|
174
|
+
For adding dynamic tags to frontend please add meta tags as follows:
|
|
175
|
+
|
|
176
|
+
```ruby
|
|
177
|
+
# some_controller.rb
|
|
178
|
+
|
|
179
|
+
def show
|
|
180
|
+
@user = User.find(params[:id])
|
|
181
|
+
set_meta_tags @user
|
|
182
|
+
end
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
For adding dynamic meta tags for existing records please run following:
|
|
186
|
+
|
|
187
|
+
```ruby
|
|
188
|
+
Model.find_each(&:save)
|
|
189
|
+
```
|
|
190
|
+
|
|
174
191
|
### Sitemap
|
|
175
192
|
|
|
176
193
|
For sitemap you need to configure as follows:
|
|
@@ -297,7 +314,7 @@ Got a bug and you're not sure? You're sure you have a bug, but don't know what t
|
|
|
297
314
|
|
|
298
315
|
## Contributing
|
|
299
316
|
|
|
300
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/
|
|
317
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/Fidenz/fi_seo. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/Fidenz/fi_seo/blob/master/CODE_OF_CONDUCT.md).
|
|
301
318
|
|
|
302
319
|
|
|
303
320
|
## License
|
|
@@ -306,4 +323,4 @@ The gem is available as open source under the terms of the [MIT License](https:/
|
|
|
306
323
|
|
|
307
324
|
## Code of Conduct
|
|
308
325
|
|
|
309
|
-
Everyone interacting in the FiSeo project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/
|
|
326
|
+
Everyone interacting in the FiSeo project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/Fidenz/fi_seo/blob/master/CODE_OF_CONDUCT.md).
|
data/fi_seo.gemspec
CHANGED
|
@@ -3,13 +3,13 @@ require_relative 'lib/acts_as_seoable/version'
|
|
|
3
3
|
Gem::Specification.new do |spec|
|
|
4
4
|
spec.name = 'fi_seo'
|
|
5
5
|
spec.version = FiSeo::VERSION
|
|
6
|
-
spec.authors = ['
|
|
7
|
-
spec.email = ['info@fidenz.com'
|
|
6
|
+
spec.authors = ['Fidenz']
|
|
7
|
+
spec.email = ['info@fidenz.com']
|
|
8
8
|
|
|
9
9
|
spec.summary = 'Flexible SEO solution for rails projects'
|
|
10
10
|
spec.description = 'This gem provides a easier solution to search engine optimization(SEO) in a rails project. This will give you the seo capabilities to your static pages and dynamic pages alike with few lines of code.
|
|
11
11
|
Also site maps are essential to the SEO of your web application. So this gem gives that capabilities with a feature to integrate google analytics.'
|
|
12
|
-
spec.homepage = 'https://github.com/
|
|
12
|
+
spec.homepage = 'https://github.com/Fidenz/fi_seo'
|
|
13
13
|
spec.license = 'MIT'
|
|
14
14
|
spec.required_ruby_version = Gem::Requirement.new('>= 2.3.0')
|
|
15
15
|
|
|
@@ -23,7 +23,7 @@ Gem::Specification.new do |spec|
|
|
|
23
23
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
|
24
24
|
spec.require_paths = ['lib']
|
|
25
25
|
|
|
26
|
-
spec.add_runtime_dependency 'activerecord'
|
|
26
|
+
spec.add_runtime_dependency 'activerecord', '>= 5.0', '< 6.1'
|
|
27
27
|
spec.add_runtime_dependency 'meta-tags', '~> 2.13'
|
|
28
28
|
spec.add_runtime_dependency 'xml-sitemap', '~> 1.3', '>= 1.3.3'
|
|
29
29
|
end
|
data/lib/fi_seo.rb
CHANGED
|
@@ -189,15 +189,27 @@ module FiSeo
|
|
|
189
189
|
end
|
|
190
190
|
|
|
191
191
|
def title_value
|
|
192
|
-
self
|
|
192
|
+
if self&.dynamic_seo&.title
|
|
193
|
+
self.dynamic_seo.title
|
|
194
|
+
else
|
|
195
|
+
self.send(self.class.seoable_fields.first) || ''
|
|
196
|
+
end
|
|
193
197
|
end
|
|
194
198
|
|
|
195
199
|
def description_value
|
|
196
|
-
self
|
|
200
|
+
if self&.dynamic_seo&.description
|
|
201
|
+
self.dynamic_seo.description
|
|
202
|
+
else
|
|
203
|
+
self.send(self.class.seoable_fields.second) || ''
|
|
204
|
+
end
|
|
197
205
|
end
|
|
198
206
|
|
|
199
207
|
def keywords_value
|
|
200
|
-
self
|
|
208
|
+
if self&.dynamic_seo&.keywords
|
|
209
|
+
self.dynamic_seo.keywords
|
|
210
|
+
else
|
|
211
|
+
self.send(self.class.seoable_fields.third) || ''
|
|
212
|
+
end
|
|
201
213
|
end
|
|
202
214
|
end
|
|
203
215
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: fi_seo
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.7
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
|
-
-
|
|
7
|
+
- Fidenz
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2020-
|
|
11
|
+
date: 2020-09-23 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activerecord
|
|
@@ -16,14 +16,20 @@ dependencies:
|
|
|
16
16
|
requirements:
|
|
17
17
|
- - ">="
|
|
18
18
|
- !ruby/object:Gem::Version
|
|
19
|
-
version: '0'
|
|
19
|
+
version: '5.0'
|
|
20
|
+
- - "<"
|
|
21
|
+
- !ruby/object:Gem::Version
|
|
22
|
+
version: '6.1'
|
|
20
23
|
type: :runtime
|
|
21
24
|
prerelease: false
|
|
22
25
|
version_requirements: !ruby/object:Gem::Requirement
|
|
23
26
|
requirements:
|
|
24
27
|
- - ">="
|
|
25
28
|
- !ruby/object:Gem::Version
|
|
26
|
-
version: '0'
|
|
29
|
+
version: '5.0'
|
|
30
|
+
- - "<"
|
|
31
|
+
- !ruby/object:Gem::Version
|
|
32
|
+
version: '6.1'
|
|
27
33
|
- !ruby/object:Gem::Dependency
|
|
28
34
|
name: meta-tags
|
|
29
35
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -63,8 +69,6 @@ description: |-
|
|
|
63
69
|
Also site maps are essential to the SEO of your web application. So this gem gives that capabilities with a feature to integrate google analytics.
|
|
64
70
|
email:
|
|
65
71
|
- info@fidenz.com
|
|
66
|
-
- tech@fidenz.com
|
|
67
|
-
- banura.r@fidenz.com
|
|
68
72
|
executables: []
|
|
69
73
|
extensions: []
|
|
70
74
|
extra_rdoc_files: []
|
|
@@ -108,7 +112,7 @@ files:
|
|
|
108
112
|
- screenshots/static-pages-seoable-details.png
|
|
109
113
|
- screenshots/static-pages-seoable-frontend.png
|
|
110
114
|
- screenshots/static-pages-seoable.png
|
|
111
|
-
homepage: https://github.com/
|
|
115
|
+
homepage: https://github.com/Fidenz/fi_seo
|
|
112
116
|
licenses:
|
|
113
117
|
- MIT
|
|
114
118
|
metadata: {}
|