For a one-off build, the following can be run:
composer install
npm install
npm run buildThis builds the JavaScript and CSS files for the project and adds them to the
./build directory.
For a live build process that watches for file changes, you can keep
npm run start running while developing for a constant build process.
JS and Sass files can be linted using npm run lint:js and npm run lint:css.
The PHP file can be linted using PHPCS. After running composer install, the
WordPress Coding standards should be installed as well.
Run ./vendor/bin/phpcs askell-registration.php --standard=WordPress to lint
the code and ./vendor/bin/phpcbf askell-registration.php --standard=WordPress
respectively to fix the linting errors and warnings automatically.
Don't forget to update version number in the readme.txt, askell-registration.php and block.json files before creating a new release of the plugin.
When the version number has been bumped up, run the commands from the Build section in addition to:
npm run plugin-zipThis creates a zip-file located in the project root, which then can be installed to WordPress directly.