2
0
mirror of https://github.com/tenrok/BBob.git synced 2026-06-14 18:42:24 +03:00

chore(core): string node walk plugin test

This commit is contained in:
Nikolay Kostyurin
2018-09-24 00:39:13 +02:00
parent b49b7435da
commit ee29d499e5
3 changed files with 42 additions and 5 deletions
+4
View File
@@ -19,6 +19,10 @@ export default function bbob(plugs) {
const parseFn = options.parser || parse;
const renderFn = options.render;
if (typeof parseFn !== 'function') {
throw new Error('"parser" is not a function, please pass to "process(input, { parser })" right function');
}
let tree = options.skipParse
? input || []
: parseFn(input, options);