🚀 Hostinger Optimized
🖥️ Server: Apache
💻 System: Linux webm015.cluster127.gra.hosting.ovh.net 6.18.42-ovh-vps-grsec-zfs+ #1 SMP PREEMPT_DYNAMIC Wed Aug 5 15:59:48 CEST 2026 x86_64
👤 User: stakrfrcol (69043)
🐘 PHP: 8.3.31
🚫 Disabled: _dyuweyrj4,_dyuweyrj4r,dl

💻 Terminal

📁 /home/stakrfrcol/agency
$

📄 transforms.js

📁 Path: ./wp-content/plugins/seo-by-rank-math/includes/modules/schema/blocks/howto/assets/src/transforms.js
📊 Size: 924 B
🔒 Perm: 0644
📝 MIME: text/plain
/**
 * WordPress dependencies
 */
import { createBlock } from '@wordpress/blocks'

/**
 * Internal dependencies
 */
import generateId from '@helpers/generateId'

/**
 * Transform yoast howto block.
 *
 * @type {Array}
 */
export default {
	from: [
		{
			type: 'block',
			blocks: [ 'yoast/how-to-block' ],
			transform: ( yoast ) => {
				const steps = yoast.steps.map( ( step ) => {
					return {
						visible: true,
						id: generateId( 'howto-step' ),
						title: step.jsonName,
						content: step.jsonText,
					}
				} )

				const attributes = {
					steps,
					titleWrapper: 'h3',
					hasDuration: yoast.hasDuration,
					days: yoast.days,
					hours: yoast.hours,
					minutes: yoast.minutes,
					description: yoast.jsonDescription,
					className: yoast.className,
					listStyle: yoast.unorderedList ? 'unordered' : '',
				}

				return createBlock( 'rank-math/howto-block', attributes )
			},
		},
	],
}
← Back📥 Raw✏️ Edit🔒 Chmod
✨ File Manager Magic ✨