@goodcastle/api-plugin-storefront

1.10.2 • Public • Published

api-plugin-example

Summary

This plugin provides a Boilerplate for creating an npm plugin for the Reaction API.

The Developer Certificate of Origin and License sections can stay as they are, assuming Apache 2 license is used (our preferred license). All other sections of this README should be updated to reflect your plugin.

Included in this example plugin

./gitlab-ci.yml

CI script that enable Gitlab to run tests, lint, and semantic release your package.

src/

The src folder is where you'll put all the plugin files. An index.js with a bear-bones registerPlugin is included.

.gitignore

A basic gitignore file

.nvmrc

.nvmrc sets your plugin to use Node v12.14.1

babel.config.cjs

If your plugin includes linting and tests, this file is required to allow esmodules to run correctly.

jest.config.cjs

If your plugin includes tests, this file is required to allow esmodules to run correctly. You'll need to update the transformIgnorePatterns and moduleNameMapper sections to include any esmodule npm packages used in your plugin.

License.md

If your plugin uses Apache 2 licensing, you can leave this file as-is. If another type of licensing is used, you need to update this file, and the README, accordingly.

package.json

The provided package.json is set up to install all needed packages and config for linting, testing, and semantic-release. You'll need to update the name, description, and add any new dependencies your plugin files use.

index.js

The entrypoint file for your npm package, will most likely just export your plugin registration from the src folder.

Dependents (0)

Package Sidebar

Install

npm i @goodcastle/api-plugin-storefront

Weekly Downloads

0

Version

1.10.2

License

Apache-2.0

Unpacked Size

187 kB

Total Files

86

Last publish

Collaborators

  • goodcastle