woocommerce/plugins/woocommerce-blocks/assets/js/base
Albert Juhé Lluveras 1d0adeed28 Replace react imports with wordpress/element (https://github.com/woocommerce/woocommerce-blocks/pull/8520)
* Replace react imports with wordpress/element

* Fix TS errors

* Update a couple of React type imports
2023-03-02 15:26:00 +01:00
..
components Replace react imports with wordpress/element (https://github.com/woocommerce/woocommerce-blocks/pull/8520) 2023-03-02 15:26:00 +01:00
context Rename the checkout events (https://github.com/woocommerce/woocommerce-blocks/pull/8381) 2023-02-17 11:03:13 +00:00
hocs Replace react imports with wordpress/element (https://github.com/woocommerce/woocommerce-blocks/pull/8520) 2023-03-02 15:26:00 +01:00
hooks Replace react imports with wordpress/element (https://github.com/woocommerce/woocommerce-blocks/pull/8520) 2023-03-02 15:26:00 +01:00
utils Allow third party methods to appear in local pickup area (https://github.com/woocommerce/woocommerce-blocks/pull/8256) 2023-02-03 08:00:24 -08:00
README.MD Avoid usage of `@wordpress/components` inside base components (https://github.com/woocommerce/woocommerce-blocks/pull/7996) 2023-01-11 17:12:06 +00:00

README.MD

Base Components/Context/Hooks

Base components are designed to be used on the frontend of a store. Due to this, we need to avoid using heavy WordPress externals as dependencies (wp-components, wp-block-editor, etc). To get around this, import from a local package instead.

e.g. Instead of importing from @wordpress/components, use:

import { Component } from 'wordpress-components';

Check the built *.assets.php files to ensure extra dependencies aren't being added to the build.