@alleyinteractive/block-editor-tools
TypeScript icon, indicating that this package has built-in type declarations

0.1.2 • Public • Published

Alley Block Editor Tools

README standard

This package contains a set of modules used by Alley Interactive to aid in building features for the WordPress block editor.

Table of Contents

Install

Install this package in your project:

npm install @alleyinteractive/block-editor-tools --save

This package assumes your project is running in an environment compatible with the WordPress block editor and is using the Dependency Extraction Webpack Plugin or similar to externalize dependencies included in WordPress. As such, this package does not include these dependencies.

Usage

To use modules from this package, import them into your files using the import declaration

import { usePostMeta } from '@alleyinteractive/block-editor-tools';

const MyComponent = () => {
	const [meta, setMeta] = usePostMeta();
	const { my_meta_key: myMetaKey } = meta;

	return (
		<TextControl
			label={__('My Meta Key', 'alley-scripts')}
			onChange={(newValue) => setMeta({ ...meta, my_meta_key: newValue })}
			value={myMetaKey}
		/>
	);
};

Changelog

0.1.0

  • Addition of Eslint configuration and rules.
  • Make peer dependency requirements lenient.
  • Add Styleint config.
  • Include Typescript types.

0.0.1

– Initial release

Development Process

This package is developed as part of the Alley Scripts project on GitHub. The project is organized as a monorepo using npm workspaces and individual packages are published to npm under the @alleyinteractive organization.

Contributing

You can contribute to this project in several ways:

Releases

This project adheres to the Semantic Versioning 2.0.0 specification. All major, minor, and patch releases are published to npm and tagged in the repo. We will maintain separate branches for each minor release (e.g. block-editor-tools/0.1) to manage patch releases while keeping future development in the main branch.

Maintainers

This project is actively maintained by Alley Interactive. Like what you see? Come work with us.

Alley logo

License

This software is released under the terms of the GNU General Public License version 2 or any later version.

Keywords

none

Install

npm i @alleyinteractive/block-editor-tools

DownloadsWeekly Downloads

198

Version

0.1.2

License

GPL-2.0-or-later

Unpacked Size

533 kB

Total Files

70

Last publish

Collaborators

  • srtfisher
  • alleyops