/**
 * @license Copyright (c) 2017-2025, CKSource Holding sp. z o.o. All rights reserved.
 * For licensing, see LICENSE.md.
 */

'use strict';

const { randomId } = require( '../utils/random-id' );

/**
 * Generates a random UUID (v4). If a prefix is provided, it will be prepended to the UUID.
 *
 * @param {String} [prefix] Optional prefix to add to the UUID
 * @return {String} The generated UUID with optional prefix
 */
hexo.extend.helper.register( 'uRandomId', randomId );
