Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save HomoEfficio/6f2176124b6c46adb7a3d8529292cf82 to your computer and use it in GitHub Desktop.
Save HomoEfficio/6f2176124b6c46adb7a3d8529292cf82 to your computer and use it in GitHub Desktop.
CodeSpitz75-2일차-숙제
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>CodeSpitz71-1</title>
</head>
<body>
abc
<section id="data"></section>
<script>
const Github = class{
constructor(id, repo){
this._base = `https://api.github.com/repos/${id}/${repo}/contents/`;
}
load(path){
const id = 'callback' + Github._id++;
const f = Github[id] = ({data:{content}})=>{
delete Github[id];
document.head.removeChild(s);
this._loaded(content);
};
const s = document.createElement('script');
s.src = `${this._base + path}?callback=Github. ${id}`;
document.head.appendChild(s);
}
_loaded(v){throw 'override!';}
};
Github._id = 0;
</script>
</body>
</html>
Copy link

ghost commented Apr 8, 2018

1(8) : 0 (전체 과제 코드의 구현이 되지 않았습니다.)
2(4) : 0 (전체 과제 코드의 구현이 되지 않았습니다.)

0/12 = 0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment