Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
:collision: Bugs in your application by email to be notified
HTML JavaScript
Branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
lib
.gitignore
README.md
default.png
mo.test.json
package.json
screenshot.png
test.js

README.md

Bugs in your application by email to be notified

Install

NPM is available for download via a simple

npm install moo-debug

Usage

var mo = require('moo-debug')('appname');

Methods

  • co - string,object
  • list - array
  • theme - string,object
  • err - error

co

  • service - string
  • setting - object
mo.co("SMTP",{service": "Gmail",
            auth: {
                "user": "JohnDoe@gmail.com",
                "pass": "xxxxxx"
            }
        })

list

  • emails - array
mo.list(['johndoe@gmail.com','example@yahoo.com']);

theme

  • dir - string
  • param object
mo.theme('/tema/template/herox/herox.html',
    param:{bla:"hegddf",stuff:"bla bla" }
 });

example theme

//herox.html
//basic email template

<h1>{{title}}</h1> // require params

{% for key in errors %}
    <p> {{key.stack}} </p> // require params
{% endfor %}


<small>Copyright {{stuff}}</small> // custom paramas..

Example template.. mo-template

err

  • err - error
seven.play('https://news.ycombinator.com/',function(err,body,res){
        if(err){

            mo.err(err);

        }else{
        console.log(body);
        }
});

Config

direction mo.json stuff

{
 "service":"SMTP",
 "setting":{
    "service": "Gmail",
    "auth": {
        "user": "JohnDoe@gmail.com",
        "pass": "xxxxxx"
    }
 },
 "list":["cobaimelan@yandex.com.tr","cobaimelan@gmail.com"],
 "theme":{
    "dir":"/tema/template/herox/herox.html",
    "param":{"bla":"stuff"}
 }
}

javascript your code stuff

mo.co().list().theme() //run code ^^

Catching erros..

MO=catch node test.js

Debug

DEBUG=* MO=catch node test.js
Something went wrong with that request. Please try again.