# extendify/3.0.4/src/Agent/lib/util.js

Extendify, version 3.0.4. 17 lines.

- Page: https://pluginprobe.com/plugins/extendify/3.0.4/code/src/Agent/lib/util.js
- Raw: https://pluginprobe.com/plugins/extendify/3.0.4/raw/src/Agent/lib/util.js
- Modified: 2026-04-27T19:36:32+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/extendify/3.0.4/code/src/Agent/lib/util.js#L10-L20`.

```javascript
export const clamp = (value, min, max) => Math.max(min, Math.min(value, max));

export const makeId = () =>
	Date.now().toString(36) + Math.random().toString(36).slice(2);

export const isInEditor = () => {
	const path = window.location.pathname;
	const params = new URLSearchParams(window.location.search);
	return path.includes('/wp-admin/post.php') && params.get('action') === 'edit';
};

export const isChangeSiteDesignWorkflowAvailable = () => {
	const { useAgentOnboarding } = window.extSharedData;

	return useAgentOnboarding;
};

```
