Skip to content

Commit

Permalink
Dimanche
Browse files Browse the repository at this point in the history
  • Loading branch information
ledoux committed May 31, 2015
1 parent f285995 commit f93298d
Show file tree
Hide file tree
Showing 19 changed files with 564 additions and 2,344 deletions.
94 changes: 75 additions & 19 deletions Coffeelogy/Coffeelogy.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -22,19 +22,61 @@ if typeof window!="undefined"
#set
exports = {}

#alias
run = (_ScriptStr,_BackFunction) ->
#define
SYS.run = (_BackFunction,_KeyStr,_PathStr) ->

#require
###
require(
[_ScriptStr],
[__PathStr],
->
#first extend
_.extend(SYS,exports)
SYS[__KeyStr]=exports
#call
_BackFunction()
)
###

#Debug
console.log(
[
"_BackFunction is \n"
_BackFunction,
"_KeyStr is \n"
_KeyStr,
"_PathStr is \n"
_PathStr,
]
)

#get
$.getScript(
_PathStr,
->

#Debug
###
console.log(
[
"l.67 Coffeelogy\n"
"Call back \n",
"__BackFunction is \n"
__BackFunction,
"__KeyStr is \n"
__KeyStr,
"__PathStr is \n"
__PathStr,
]
)
###

#first extend
SYS[_KeyStr]=eval(_KeyStr)


#call
_BackFunction()
)

else

Expand All @@ -51,12 +93,27 @@ else
#set
SYS.SideStr = "server"

run = (_ScriptStr,_BackFunction) ->
#define
SYS.run = (_BackFunction,_KeyStr,_PathStr) ->

#Debug
###
console.log(
[
"_BackFunction is \n"
_BackFunction,
"_KeyStr is \n"
_KeyStr,
"_PathStr is \n"
_PathStr,
]
)
###

#require
ModuleObject = require(_ScriptStr)
ModuleObject = require(_PathStr)

#debug
#Debug
###
console.log(
"ModuleObject is \n",
Expand All @@ -65,26 +122,25 @@ else
###

#extend
SYS._.extend(SYS,ModuleObject)
SYS[_KeyStr]=ModuleObject

#back call like...
_BackFunction()

#exports
exports.SYS = SYS

#debug
###
console.log(
"************************\n"
"Welcome to Coffeelogy \n",
"We are " + SYS.SideStr + " side ! \n",
#"require function is ",
#require
#require,
#"SYS is \n",
#SYS
)
###


#require
run(
"./Teamer/src.js",
->
console.log(
"HHHH\n",
SYS.TeamerClass
)
)
72 changes: 61 additions & 11 deletions Coffeelogy/Coffeelogy.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 10 additions & 0 deletions Coffeelogy/Draft/Coffeelogy.coffee
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
###/#################/#
# Define a require
# server or client side working
###/###

unique = require('uniq');

data = [1, 2, 2, 3, 4, 5, 5, 5, 6];

console.log(unique(data));
Loading

0 comments on commit f93298d

Please sign in to comment.