lib/replicator.js
function declare(name, namespace, opts) {
	// Delay requiring the Replicant class until here, otherwise cryptic errors are thrown. Not sure why!
	const Replicant = require('./replicant');
	return new Replicant(name, namespace, opts);
}
function declare(name, namespace, opts) {
	// Delay requiring the Replicant class until here, otherwise cryptic errors are thrown. Not sure why!
	const Replicant = require('./replicant');
	return new Replicant(name, namespace, opts);
}
function declare ( name , namespace , opts ) { // Delay requiring the Replicant class until here, otherwise cryptic errors are thrown. Not sure why! const Replicant = require ( './replicant' ) ; return new Replicant ( name , namespace , opts ) ; }
Declares a Replicant.
@param {string} name - The name of the Replicant to declare.
@param {string} namespace - The namespace to which this Replicant belongs.
@param {object} [opts] - The options for this replicant.
@param {*} [opts.defaultValue] - The default value to instantiate this Replicant with. The default value is only
applied if this Replicant has not previously been declared and if it has no persisted value.
@param {boolean} [opts.persistent=true] - Whether to persist the Replicant's value to disk on every change.
Persisted values are re-loaded on startup.
@param {string} [opts.schemaPath] - The filepath at which to look for a JSON Schema for this Replicant.
Defaults to `nodecg/bundles/${bundleName}/schemas/${replicantName}.json`.
@returns {object}
Declares a Replicant .