how can i create a folder structure using this json structure
{
"europe": {
"poland":{},
"france":{},
"spain":{},
"greece":{},
"UK":{},
"germany":"txt"
},
"Asia": {
"india":"xml"
},
"Africa":null
}
in such a way that
- properties with object values become folders
- properties with string values are files and their values represent their extensions
- properties with null values are files with no extension
- nested objects become nested folders
anyone know how to do this in nodejs?
Africais a file, not a folder ?