We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 23552da + 5dde570 commit 164f866Copy full SHA for 164f866
1 file changed
index.js
@@ -46,6 +46,20 @@ module.exports.get = function (name) {
46
throw new Error("An instance with the name `%s` was not found.".replace("%s", name));
47
};
48
49
+/**
50
+ * Check if an instance has been created.
51
+ * @method has
52
+ * @param {String} name
53
+ * @returns {Boolean}
54
+ */
55
+module.exports.has = function (name) {
56
+ var instance = getSingle(name);
57
+ if (instance) {
58
+ return true;
59
+ }
60
+ return false;
61
+};
62
+
63
/**
64
* Start the Browsersync service. This will launch a server, proxy or start the snippet
65
* mode depending on your use-case.
0 commit comments