jekyll-react 0.0.3 → 0.0.4

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
  SHA1:
3
- metadata.gz: 123fa4e15882ce121ae0549d339424ea0266421c
4
- data.tar.gz: 681cd84070904dcc46e3b31931104a3a0c331fce
3
+ metadata.gz: c7fd4812fccf2ad9f4ef69280805e8a27fe25f26
4
+ data.tar.gz: 20f471277d6c811b1a240d8bd56f0928fb097db3
5
5
  SHA512:
6
- metadata.gz: c03898c8dd0fb1b108766590c1a1fa80b66ff2cfa53ed6d80807208af1de0d28beece5341866e2c2eaa4288ba03b10d4d51dfdc34d04d45b686bd22979b19b08
7
- data.tar.gz: '09c18db8000208abf1845ec8da4bd2bafbff6f8660a7d6db62a06b97c40038ad0f5f08541bbd213f6ac4943582ffd84f855890843414e6881cd2906d91fa4dd3'
6
+ metadata.gz: 51e6d6420522ae0ab73c7e6de5f04ae0e05cc9238839f63fbd2cea6ebf93ac80306f19fae6d11c0ff2504141d324396cff2f409c28734d6dfe731ae48a922c6f
7
+ data.tar.gz: df4fd5bb8f289577170e3c4c7e3d2939b65b679a84c33dbd3a298b9bff963ae3a2be12b06025743fed8e137dd2e80b03abf7de65bfa98e4a3c0dd5e339646042
data/README.md CHANGED
@@ -4,7 +4,7 @@ This is a Jekyll plugin which will generate a JSON file of select configuration
4
4
 
5
5
  to add properties to be generated, simply edit your `_config.yml`
6
6
 
7
- This Plugin was inspired and made possible by https://github.com/18F/jekyll_pages_api
7
+ This Plugin was inspired by https://github.com/18F/jekyll_pages_api
8
8
  This plugin was made out of a custom-use-case (Jekyll and ReactJS) that I think does not belong in the jekyll_pages_api plugin,
9
9
  however, if 18F decides that this functionality would be welcome in their plugin, I would be more than happy to contribute (Though, i'm not the best at Ruby)
10
10
 
@@ -1,7 +1,7 @@
1
1
 
2
2
  Gem::Specification.new do |spec|
3
3
  spec.name ="jekyll-react"
4
- spec.version ="0.0.3"
4
+ spec.version ="0.0.4"
5
5
  spec.authors ="Andrew Plaza (InsidiousMind)"
6
6
  spec.email =["aplaza@liquidthink.net"]
7
7
  spec.summary =%q{A Jekyll Plugin that generates a JSON file of configuration variables and Pages}
@@ -24,6 +24,7 @@ module Jekyll
24
24
  config_json = config.to_json
25
25
  new_page('config.json', config_json, self.dest_dir)
26
26
  parse_pages
27
+ parse_data
27
28
  end
28
29
 
29
30
  def parse_pages
@@ -39,6 +40,12 @@ module Jekyll
39
40
  end
40
41
  end
41
42
  end
43
+
44
+ def parse_data
45
+ @site.data.each do |site_file|
46
+ new_page("#{site_file[0]}.json", site_file.to_json, self.dest_dir)
47
+ end
48
+ end
42
49
 
43
50
  def new_page(name, data, dir)
44
51
  page = PageWithoutAFile.new(@site, File.dirname(__FILE__), dir, name.to_s)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-react
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Plaza (InsidiousMind)
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-01-07 00:00:00.000000000 Z
11
+ date: 2017-01-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll