-
-
Save JamesHagerman/163ae0a9e6a5806773a8dde865c9580d to your computer and use it in GitHub Desktop.
NoFlo list components and metadata
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var rootdir = './'; | |
var loader = new noflo.ComponentLoader(rootdir); | |
loader.listComponents(function() { | |
console.log(loader.components); | |
Object.keys(loader.components).forEach(function(name) { | |
loader.load(name, function(derp, component) { | |
console.log(name); | |
console.log(component.description); | |
// for each port, should look at the .options key | |
// it has "description, type, datatype etc" | |
console.log(component.inPorts); | |
console.log(component.outPorts); | |
}); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment