Skip to content

Commit

Permalink
添加js
Browse files Browse the repository at this point in the history
  • Loading branch information
E2007 李小刚 authored and E2007 李小刚 committed Mar 29, 2019
1 parent c98f20f commit 6958736
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,6 @@ Git!!!!

第二次写!!!
哈哈!!

第三次写 !!!
拉下来写!!
17 changes: 17 additions & 0 deletions git-f.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
(function(scoped,na){
Function.prototype.method=function(name,fn){
this.prototype[name]=fn;
return this
}
function Fa(name){
this.name=name;
};
Fa.method('getName',function(){
return this.name
}).method('setName',function(){
return this.name+'ceshi'
})
scoped.na=new Fa('小刚');
}(window,$))

console.log($.getName())

0 comments on commit 6958736

Please sign in to comment.