mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
Add function docs
This commit is contained in:
parent
1fd4fbc299
commit
5e9195ab99
@ -1473,7 +1473,14 @@ RED.nodes = (function() {
|
||||
}
|
||||
/**
|
||||
* Converts the current node selection to an exportable JSON Object
|
||||
**/
|
||||
* @param {Array<Node>} set the node selection to export
|
||||
* @param {Object} options
|
||||
* @param {Record<string, boolean>} [options.exportedIds]
|
||||
* @param {Record<string, boolean>} [options.exportedSubflows]
|
||||
* @param {Record<string, boolean>} [options.exportedConfigNodes]
|
||||
* @param {boolean} [options.includeModuleConfig]
|
||||
* @returns {Array<Node>}
|
||||
*/
|
||||
function createExportableNodeSet(set, {
|
||||
exportedIds,
|
||||
exportedSubflows,
|
||||
@ -1561,9 +1568,13 @@ RED.nodes = (function() {
|
||||
return nns;
|
||||
}
|
||||
|
||||
// Create the Flow JSON for the current configuration
|
||||
// opts.credentials (whether to include (known) credentials) - default: true
|
||||
// opts.dimensions (whether to include node dimensions) - default: false
|
||||
/**
|
||||
* Converts the current configuration to an exportable JSON Object
|
||||
* @param {object} opts
|
||||
* @param {boolean} [opts.credentials] whether to include (known) credentials. Default `false`.
|
||||
* @param {boolean} [opts.dimensions] whether to include node dimensions. Default `false`.
|
||||
* @returns {Array<Node>}
|
||||
*/
|
||||
function createCompleteNodeSet(opts) {
|
||||
var nns = [];
|
||||
var i;
|
||||
@ -2990,6 +3001,12 @@ RED.nodes = (function() {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the module list for the given nodes
|
||||
* @param {Array<Node>} nodes the nodes to search in
|
||||
* @returns {Record<string, string>} an object with {[moduleName]: moduleVersion}
|
||||
*/
|
||||
function getModuleListForNodes(nodes) {
|
||||
const modules = {}
|
||||
nodes.forEach(n => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user