forked from sashin/sashinexists
run npm install to generate a package lock
This commit is contained in:
16
node_modules/@weborigami/origami/src/dev/log.js
generated
vendored
Normal file
16
node_modules/@weborigami/origami/src/dev/log.js
generated
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
import yaml from "../origami/yaml.js";
|
||||
|
||||
/**
|
||||
* Log the first argument to the console as a side effect and return the second
|
||||
* argument. If no second argument is provided, return the first argument.
|
||||
*
|
||||
* @this {import("@weborigami/types").AsyncTree|null}
|
||||
* @param {any} object
|
||||
* @param {any} [result]
|
||||
*/
|
||||
export default async function log(result, object = result) {
|
||||
let text = object !== undefined ? await yaml.call(this, object) : "undefined";
|
||||
text = text?.trim();
|
||||
console.log(text);
|
||||
return result;
|
||||
}
|
||||
Reference in New Issue
Block a user