Skip to content

Instantly share code, notes, and snippets.

@lethe2211
Last active August 29, 2015 14:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lethe2211/cd704d6aa0d177dc1ee6 to your computer and use it in GitHub Desktop.
Save lethe2211/cd704d6aa0d177dc1ee6 to your computer and use it in GitHub Desktop.
app/assets/javascripts/main.js
$(document).ready(function(){
// 省略 //
// JSONの読み込み(static_pages/get_citationを呼び出すことで,変数dataにJSONが返ってくる)
var data = $.getJSON('get_citation',function(data){
sys.graft({nodes:data.nodes, edges:data.edges})
});
// 省略 //
})(this.jQuery)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment