Created
December 16, 2012 07:41
-
-
Save shawjia/4304077 to your computer and use it in GitHub Desktop.
load module written in CoffeeScript
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### | |
load from CoffeeScript | |
just load, nothing else | |
### | |
{hello} = require './test' | |
hello() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('coffee-script'); | |
hello = require('./test').hello; | |
hello(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
console.log 'load test.coffee' | |
exports.hello = -> | |
console.log 'hello from test' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment