- Install the following open source Wordpress Plugins into your WP store:
- add this to wp-config.php:
define( 'LOGGED_IN_COOKIE', 'wordpress_logged_in_vsf' );
- If you want favourites function you must add a plugin for this. See example plugin here. You also need to enable favourites in middleware config:
module.exports = {
integrations: {
woocommerce: {
location: '@vue-storefront/woocommerce-api/server',
configuration: {
api: process.env.WOOCOMMERCE_GRAPHQL,
wishlist: true
}
}
}
};
- If you want to keep using the woocommerce checkout you need to change the woo cart session handling. See example plugin here.
-
Prepare your wordpress installation as above.
-
Copy .env.example to .env inside packages/theme and enter your wordpress site URL with GraphQL endpoint.
-
Install all required dependencies:
yarn install
- (optional) Then you can verify if everything works properly by building all three projects:
yarn build
- If everything built properly, you can start developing with:
yarn dev
Want to contribute? Ping us on woocommerce
channel on our Discord!
- NodeJS v14 or later
- Fork the repo
- Clone your fork of the repo
example: git clone https://github.com/vuestorefront/woocommerce.git cd woocommerce
- Run
yarn
to install dependencies - Build dependencies
yarn build:api-client && yarn build:composables
- Run
yarn dev:theme
to run theme. You can find other commands inpackage.json
- If you need HMR on Api Client/Composables run
yarn dev:api-client
oryarn dev:composables
on a separate terminal window.
If you have any questions about this integration we will be happy to answer them on woocommerce
channel on our Discord.
andreasradloff 💻 |
This project follows the all-contributors specification. Contributions of any kind welcome!