blog.trnck.dev
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

init repo

+109
+3
Gemfile
··· 1 + gem 'jekyll-jsonball' 2 + gem 'jekyll-watch' 3 + source 'https://rubygems.org'
+25
Gemfile.lock
··· 1 + GEM 2 + remote: https://rubygems.org/ 3 + specs: 4 + ffi (1.10.0) 5 + jekyll-jsonball (0.0.1) 6 + jekyll-watch (2.1.2) 7 + listen (~> 3.0) 8 + listen (3.1.5) 9 + rb-fsevent (~> 0.9, >= 0.9.4) 10 + rb-inotify (~> 0.9, >= 0.9.7) 11 + ruby_dep (~> 1.2) 12 + rb-fsevent (0.10.3) 13 + rb-inotify (0.10.0) 14 + ffi (~> 1.0) 15 + ruby_dep (1.5.0) 16 + 17 + PLATFORMS 18 + ruby 19 + 20 + DEPENDENCIES 21 + jekyll-jsonball 22 + jekyll-watch 23 + 24 + BUNDLED WITH 25 + 2.0.1
+12
_config.yml
··· 1 + title: brandonrosage 2 + description: description XYZ 3 + 4 + plugins: 5 + - jekyll-jsonball 6 + 7 + sass: 8 + sass_dir: node_modules 9 + 10 + jekyll_get: 11 + data: user 12 + json: 'https://api.github.com/users/brandonrosage'
+1
_site/README.md
··· 1 + # profile-generator
+34
_site/index.html
··· 1 + <!doctype html> 2 + <html> 3 + <head> 4 + <meta charset="utf-8"> 5 + <title>Home</title> 6 + </head> 7 + <body> 8 + {{ site.title }} 9 + {% jsonball feed from url https://api.github.com/users/brandonrosage %} 10 + {% for user in feed %} 11 + <h1 style="color:red;">{{ user.name }}</h1> 12 + {% endfor %} 13 + 14 + <header></header> 15 + <script> 16 + var body = document.querySelector('body'); 17 + var requestURL = 'https://api.github.com/users/brandonrosage'; 18 + var request = new XMLHttpRequest(); 19 + request.open('GET', requestURL); 20 + request.responseType = 'json'; 21 + request.send(); 22 + 23 + request.onload = function() { 24 + populateBody(request.response); 25 + } 26 + 27 + function populateBody(jsonObj) { 28 + var myH1 = document.createElement('h1'); 29 + myH1.textContent = jsonObj['name']; 30 + body.appendChild(myH1); 31 + } 32 + </script> 33 + </body> 34 + </html>
+34
index.html
··· 1 + <!doctype html> 2 + <html> 3 + <head> 4 + <meta charset="utf-8"> 5 + <title>Home</title> 6 + </head> 7 + <body> 8 + {{ site.title }} 9 + {% jsonball feed from url https://api.github.com/users/brandonrosage %} 10 + {% for user in feed %} 11 + <h1 style="color:red;">{{ user.name }}</h1> 12 + {% endfor %} 13 + 14 + <header></header> 15 + <script> 16 + var body = document.querySelector('body'); 17 + var requestURL = 'https://api.github.com/users/brandonrosage'; 18 + var request = new XMLHttpRequest(); 19 + request.open('GET', requestURL); 20 + request.responseType = 'json'; 21 + request.send(); 22 + 23 + request.onload = function() { 24 + populateBody(request.response); 25 + } 26 + 27 + function populateBody(jsonObj) { 28 + var myH1 = document.createElement('h1'); 29 + myH1.textContent = jsonObj['name']; 30 + body.appendChild(myH1); 31 + } 32 + </script> 33 + </body> 34 + </html>