/
githubmirror
/
gutenberg
Обзор
Документация
Войти
/
githubmirror
/
gutenberg
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
trunk
packages/create-block-interactive-template/index.js
50 строк
1 KB
Marco Ciampini
ESLint: Replace strict config with bulk suppressions (#81248)
07 авг 2026, 14:34
Не верифицирован
07 авг 2026, 14:34
7f43eaf
Код
Авторство
О чём код?
const { join } = require( 'path' ); module.exports = { defaultValues: { slug: 'example-interactive', title: 'Example Interactive', description: 'An interactive block with the Interactivity API.', dashicon: 'media-interactive', npmDependencies: [ '@wordpress/interactivity' ], customPackageJSON: { files: [ '[^.]*' ] }, supports: { interactivity: true, }, viewScript: null, viewScriptModule: 'file:./view.js', render: 'file:./render.php', example: {}, folderName: './src/$slug', customScripts: { build: 'wp-scripts build --experimental-modules --blocks-manifest', start: 'wp-scripts start --experimental-modules --blocks-manifest', }, }, variants: { default: {}, typescript: { slug: 'example-interactive-typescript', title: 'Example Interactive TypeScript', description: 'An interactive block with the Interactivity API using TypeScript.', viewScriptModule: 'file:./view.ts', }, 'client-side-navigation': { slug: 'example-interactive-client-side-navigation', title: 'Example Interactive Client-Side Navigation', description: 'An interactive block demonstrating client-side navigation with the Interactivity API Router.', blockTemplatesPath: join( __dirname, 'block-templates-client-side-navigation' ), npmDependencies: [ '@wordpress/interactivity', '@wordpress/interactivity-router', ], }, }, pluginTemplatesPath: join( __dirname, 'plugin-templates' ), blockTemplatesPath: join( __dirname, 'block-templates' ), };