Blocks module allows you to add fully configurable blocks to render custom content in your shop, wherever you want.
- Blocks
- Block groups
- Many block types available through extensions
- Designed to be very extensible
Get started
From PrestaShop installation root:
cd modules
git clone https://github.com/Kaudaj/kjblocks.git
cd kjblocks
composer install
cd _dev
npm install
npm run build
cd ../../..
bin/console pr:mo install kjblocks
tests/php/.phpstan_bootstrap_config.php
For GrumPHP: Set PrestaShop installation path for PHPStan task.
Replace default path with the root path of a stable PrestaShop environment.
Here are some useful commands you could need during your development workflow:
composer grum
Run GrumPHP tasks suite.composer header-stamp
Add license headers to files.composer autoindex
Add index files in directories.composer dumpautoload -a
Update the autoloader when you add new classes in a classmap package (src
andtests
folder here).npm run watch
(in_dev
folder) Watch for changes in_dev
folder and build automatically the assets inviews
folder. It's recommended to run it in background, in a dedicated terminal.npm run lint-fix
(in_dev
folder) Run ESLint fixernpm run prettier-fix
(in_dev
folder) Run Prettier formatting
If you want to add your own block type, start with kjblocksexampleextension. It's a documented example extension which add an example type. Check this repository to know how to start!
PrestaShop | >=8.0.0 |
PHP | >=7.2 for production and >=8.0 for development |
Multishop | ✔️ |
You can report issues in this very repository.
As it is an open source project, everyone is welcome and even encouraged to contribute with their own improvements!
To contribute in the best way possible, you want to follow the PrestaShop contribution guidelines.
Feel free to contact us by email at info@kaudaj.com.