ciment
ciment
is a library for generating comment-String rapidly. Include javascript, CSS and HTML commnets manipulation.
var comment = require('ciment');
comment.single('hello world');
comment.block('hello world');
'hello world'.single();
'hello world'.block();
'hello world'.block().decomment();
Install
For node with npm:
npm install ciment
And use with var comment = require("ciment")
API
Base function
comment.decomment(content);
Remove the first wrapper comment form this string
Module function
comment.single("comment text");
Return a single line comment string
comment.block("comment text");
Return a normal block comment string
comment.title("comment text");
Return a block comment string like comment title
comment.banner("comment text\nhello world");
Return a banner block comment string
comment.tag("<div>comment text</div>");
Return a html tag comment string
Prototype function
"comment text".single();
"comment text".block();
"comment text".title();
"comment text".banner();
"<div>comment text</div>".tag();