laravel-grapesjs
laravel-grapesjs copied to clipboard
Here some test on Laravel 10, and feedback.
Problem Identification and Solutions
During my testing phase, I identified a specific issue. Here are the steps to resolve it:
Installation and Issues Faced
After successfully installing the package, when you proceed with the provided guide, you might come across the following challenges:
-
CKEditor Missing Issue:
- There might be a missing
ckeditor
due to version incompatibilities. - To adjust your
laravel-grapesjs
config file, refer to this URL. Ensure to cache your config after updating this file. - The version from the aforementioned CodePen example can help rectify the CKEditor missing issue.
- There might be a missing
-
Authentication Middleware Issue:
- When you write a code on the controller to render the editor page, you may find that the
auth middleware
prevents the save button from functioning. - Adjust this in the config file as per your requirements. Alternatively, if you don't wish to modify the config, ensure that Laravel login is enabled first. Then, test with a logged-in user on the editor page.
- When you write a code on the controller to render the editor page, you may find that the
-
Template/Block Types:
- Two types of templates/blocks are available for this library: either global or model-specific. Unfortunately, both cannot be enabled simultaneously.
- It would be beneficial if both could be enabled in the model setting, perhaps by inserting a folder array or similar.
-
PDF Export:
- The PDF export function works well, but I observed error codes in the debug console. I'm still investigating a solution for this.
-
File Upload Path Issue:
- Images or files uploaded have a filename with a localhost URL rather than a domain-specific one. I'm still in the process of identifying where to make this adjustment.
Final Thoughts
This is, by far, the best Laravel package for GrapesJS. I've tried several others, but they weren't as seamless. This one stands out as being the lightest and easiest to set up. I'll provide more feedback after testing other GrapesJS features.
@irvine48 Any chance you have information for creation of a full project, from project build to editing? I'm relatively new to Laravel, and I feel there are some key steps I'm missing with the readme of the project.