• +91 9806724185,+91 9685733903
  • +91 9806724185

 

Those who are familiar with WordPress have probably heard of this new editor called Gutenberg. If you have no idea what I am talking about, don’t worry.

Gutenberg is the latest user friendly editor that everyone trying to integrate. It gives option to create custom blocks and various types of elements which make your content area more decent and professional.

laraberg

About Laraberg :

This is where our Laravel plugin, Laraberg, comes in. It takes all the configuration you would have to do to get GutenbergJS running in your Laravel application, and puts it into an easy to install package. After installing you’re free to use to Gutenberg editor in any way you see fit, from entire pages for your website to small sections on your webshop’s product detail page.

What does Laraberg do :

The goal for Laraberg is to give developers the ability to add the Gutenberg editor to any page they like in a way that is as easy as possible, but at the same time it has to prove enough options to tailor the editor so it can fit into any Laravel project out there. To make this possible there were a few problems to solve.

Since GutenbergJS is ‘only’ a standalone version of Gutenberg, it does not implement any of the WordPress functionality that the editor needs. This means that Laraberg has to come with its own implementations for some of those.

  • API endpoints :

    Some of Gutenberg’s blocks are dynamic, those are the reusable blocks, and the embed blocks. For those blocks Laraberg provides API endpoints that retrieve the necessary data to render those blocks inside the editor. And, in the case of reusable blocks, Laraberg also provides the endpoints to create, update and delete those blocks.

  • Mock data :

    A lot of data that Gutenberg requests from WordPress is irrelevant for Laraberg, and because of that we can send standard mock data whenever the editor requests this information. This includes requests like the theme’s capabilities, the available taxonomies and the different post types.

  • Content rendering :

    When a page made with Gutenberg gets submitted, the resulting content is not always fully functional HTML. When a page has any dynamic blocks inside of it, there is some processing that has to be done before the content will show correctly.

Besides those points there were some more problems to solve, like replacing the WordPress media library, making Gutenberg’s content easily accessible and providing configuration options for the API endpoints.

Final Words :

If you would like to give Laraberg a try, the release is available on Github. If you want to Develop your own website in Laravel Framework, feel free to Contact us !!

Related Posts

Laravel Framework

Laravel v/s Ruby on Rails: In-depth Comparison of Frameworks

Laravel is a modern web application framework, that design web application easily and rapidly. It can perform the customization of the web application with equal ease. It is an open-source and highly used framework, written Read more…

Laravel Framework

Laravel Homestead Benefits as Your Development Environment

  Laravel Homestead is an official, pre-packaged Vagrant box that provides you a wonderful development environment without requiring you to install PHP, a web server, and any other server software on your local machine. No Read more…

Laravel Framework

Laravel Shift : Upgrade Laravel Versions Safely

  Laravel Shift is a service that scans your Laravel application and automatically creates a pull request for upgrading Laravel. All you have to do is just choose a repository and pay some money. Some Read more…