0.0.5 • Published 5 years ago

mkdirfile v0.0.5

Weekly downloads
3
License
ISC
Repository
-
Last release
5 years ago

Recursively mkdir and file with empty content.

Function like mkdirf, but this is function call.

Version: 0.0.4

example:

const dirmakef = require("./index");
dirmakef.create(["cn/cc/xx.js", "cn/dd/x.html"]);
dirmakef.jsonToFile(
{
    "a": "b",
    "c": {
        "d": {
            "e": {
                "f":{
                    "g": "h"
                },
                "i": {
                    "j": "k"
                },
                "l": {
                    "j": "k.html"
                }
            }
        },
        "i": {
            "j": "k"
        }
    }
}
);

var x = {
    "a": "b",
    "c": {
        "d": {
            "e": [
                {
                    "g": "h"
                },
                 {
                    "j": "k"
                },
                {
                    "j": "k.html"
                }
            ]
        },
        "i": {
            "j": "k"
        }
    }
};

dirmakef.jsonToFile(x);