Skip to content

coderaiser/inline-io

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Inline

Replaces link tags with inline style tags.

Install

npm i inline-io -g

Use

As standalone

Usage: inline-io <file>

As module

npm i instal-io --save
var inline  = require('inline-io'),
    path    = require('path'),
    name    = 'test/index.html',
    dir     = path.dirname(name);

fs.readFile(name, function(error, data) {
    if (error)
        console.log(error);
    else
        inline(data, dir, function(error, result) {
            console.log(error || result);
        });
});

License

MIT