Skip to content

fullerjs/common-js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Common-js like modules for browser tool for Fuller

Build everything with right tool

For more info about fuller

CommonJS

Tiny and deadly simple commonJS (nodejs like) module realization. It consists from just two functions require and exports. You can write your client js like usual nodejs module.

    var a = require('a');
    var b = function () {

    }
    exports('b', b);

Fuller will wrap all, app and each module, in closures. So your modules will be availible only for your app. If you need to make your module global (to be avalible outside your app), just use

    exports('b', b, true);

Options

  • prologue – string will be inserted at the begining of the stream",
  • epilogue — string will be inserted at the end of the stream",
  • itemPrologue — string will be inserted before every item in the stream",
  • itemEpilogue — string will be inserted after every item in the stream"

About

Common-js like modules for browser tool

Resources

License

Stars

Watchers

Forks

Packages

No packages published