For the last years I’ve been using LemonSqueezy as my ecommerce provider to sell my plugins. For a long time I was genuinely happy with it. The product hit most of the boxes I cared about: selling digital products, newsletter, and affiliates. Overall, the service was solid enough that I could live with the rough edges. Stripe acquires LemonSqueezy… and everything freezes That changed when Stripe…
This weekend I had a very nice surprise: My latest blog post on gatographql.com made it to the top of Google's search results, when searching for "wordpress core graphql": I noticed because, as I woke up on Sunday morning and I checked my traffic, I saw a wonderful spike: By the end of the day, that blog post had brought in near 800 visitors (and they kept arriving the following day): I believe…
Well, that took time! After several months, I finally launched the site for my plugin GraphQL API for WordPress: https://gatographql.com It took so long, because when you're doing everything on your own (which is my case, I don't have a team), you literally need to do everything. So to make this website, I had to learn so many things: Jamstack + Eleventy CSS animations Screencasting And I even had…
Note: This blog post has been crossposted from gatographql.com (the GraphQL API for WordPress plugin's new site). I released version 0.7 of the GraphQL API for WordPress , supporting mutations, and nested mutations! 🎉 Here is a tour showing the new additions. 1. Mutations! 🚀 GraphQL mutations enable to modify data (i.e. perform side-effect) through the query. Mutations was the big item still…
I've written a step-by-step guide about transpiling PHP code, from PHP 7.4 to 7.1, when creating a WordPress plugin: Coding in PHP 7.4 and deploying to 7.1 via Rector and GitHub Actions It explains all the hows and whys: Why the target is PHP 7.1 and not 5.6 Which are the PHP features from each PHP version that our code can support How to find out which 3rd party dependencies must be transpiled…
I've written a new article about Gutenberg (the WordPress editor), exploring: 👉 What is the most effective way to reuse code, within a (single or multi-block) WordPress plugin? The answer is here: Reusing Functionality for WordPress Plugins with Blocks Enjoy!
I've learnt about Caleb Porzio's sponsorware model as a way to fund an open source project. The idea is to release a new feature only to the funders and, once you got X new funders, only then the new feature becomes open source, available to everyone. But I haven't seen much success with this strategy yet to fund my open source plugin . The reason is clear: Sponsorware initially worked for Caleb…
A few weeks ago I added this comment in WPTavern , on an article where WordPress founder's Matt Mullenweg clarifies his earlier remarks that the Jamstack is "a regression for the vast majority of the people adopting it". Since I like owing my own content, I reproduce it here in my own blog. I think Matt’s brutal honesty is welcome, because most information out there about the Jamstack praises it.…
My plugin GraphQL API for WordPress just got a new sponsor! This is the second sponsor that I get, and the first one at the u$d 1400/m tier (the other was is at u$d 70/m). This is a huge step forward, since it gives me the economic certainty as to keep developing the plugin (at least for the short/medium term... I still need a few more sponsors for it to become a living wage and long-term economic…
My talk "Intro to the GraphQL API for WordPress" for the WordPress London meetup from last week is now available in Youtube : My presentation starts at 25:37. It is only around 20 min long (15 min presenting + 5 min of Q&A). Please check it out. It's a succinct summary of the benefits of using GraphQL in WordPress, through my plugin GraphQL API for WordPress . These are the slides : I hope you…
Last week I made a proposal to add embeddable fields to GraphQL , but it didn't get a lot of support. I got the feedback that the extra complexity added to the server doesn't justify the benefits of this new feature, as in this comment on Reddit (which I replied to through this post ). My proposed feature then appears to be not about GraphQL as we know it nowadays, but about an über GraphQL, or…
This post is my response to this comment on Reddit concerning my proposal to add embeddable fields to GraphQL . If we want to make GraphQL good at transforming data, we need much more than string interpolation. I don't disagree with this, but I don't have a clear answer. If we allow String interpolation, should we do the same for Int s, such as allowing additions or substractions? I'd say no, but…
I'd like to make a proposal for a new feature for GraphQL, not to be appended to the official spec , but as an optional feature that GraphQL servers may decide to support (similar to the GraphQL Cursor Connections spec ). This post is part of the groundwork to find out if there is support for this feature within the GraphQL community. If there is, only then I'll submit it as a new issue to the…
I have just released version 0.6 of the GraphQL API for WordPress 🎉. This is a mighty new version, with several new features and improvements : ✅ The GraphiQL Explorer has been added to all the GraphiQL clients , including the public ones ✅ Added support for GitHub Updater , to enable self-updating when there's a new version ✅ The plugin is coded with PHP 7.4 , and can run with PHP 7.1 ✅…
2 days ago I subscribed to GitHub sponsors to fund my work on the GraphQL API for WordPress , and I already got my first sponsor ! Following the example set by Caleb Porzio (who's making more than u$d 100k/y doing open source ), I have decided to use the sponsorware model to fund my project. It works like this: Whenever I get 10 new sponsors (at u$d 14/m), I start developing the most up-voted…
I wrote a new article for my series on designing a GraphQL server for the LogRocket block: Adding directives to the schema in code-first GraphQL servers This time, I explore several topics: A strategy to add directives to the schema when there is no SDL Decoupling the query into 2: requested and executable A potential solution for implementing the flat chain syntax Adding directives to the schema…
Because Couchsurfing is dead (or, more appropriately, Couchsurfing has been killed), I requested to delete my account from the site. And it's been done: my profile does not exist anymore. But, surprise surprise, they had not deleted my photos! For instance, this photo of mine was still hosted in their cloud: These guys should have deleted all my data, absolutely all of it, including photos. To be…
Today I released v0.3 for plugin GraphQL API for WordPress , shipping one of the most urgent requests: documentation for the plugin! The plugin now ships 37 modules from 10 categories, distinguished by color: The docs have been implemented as Markdown, and they are opened when clicking on the View details link below each module: Since Markdown can also be viewed directly in the GitHub repo , I…
Update 23/01/2021: I created the guides for the Multiple Execution Query in gatographql.com : Demo Explanation It's been only 15 days since releasing the GraphQL API for WordPress , and I couldn't help myself, so this week I added yet a new feature: the server can now execute multiple queries in a single operation. This is not query batching . When doing query batching, the GraphQL server executes…
The GraphQL API for WordPress plugin ( launched last week ) has plenty of PHP dependencies, managed through Composer. These dependencies, which are located under vendor/ , are not stored in the GitHub repo, because they do not belong there. However, these dependencies must be inside the .zip file when installing the plugin in the WordPress site. Then, when and how do we add them into the release?…
When announcing the launch of my brand-new GraphQL API plugin for WordPress on Reddit , I got this question: Why build your own when one already , and is developed by a gatsby dev? I reproduce my response here. Why I built GraphQL API when there already was WPGraphQL I can reply to this question from 3 different angles: 1. Personal angle I actually started working on this project much earlier than…
Update 04/02: The plugin is now scoped ! So it is fully ready for production, and will be soon uploaded to wp.org 🥳 Update 23/01: The GraphQL API for WordPress has its own site now: gatographql.com . Yesterday I launched the project I've put all my efforts into: the GraphQL API for WordPress , a plugin which enables to retrieve data from a WordPress site using the increasingly popular GraphQL…
Yesterday I had a new article about WordPress Gutenberg published for the LogRocket blog: Essentials for building your first Gutenberg block This article gives a few tips for starting a new Gutenberg project, as I discovered them in my own journey. It's mainly useful for newbies, who either haven't started yet, or have recently begun and are navigating uncharted waters. As always, I hope you enjoy…
Because Couchsurfing is dead , I requested to get all my data from the site , and got the images too. Here they are, the images of some of my travels, when I was young and energetic (I was even smiling in many of those pics!):
I started using Gutenberg several months ago, so I'm in that stage of being an experienced newbie. Coming from a PHP background, not much JS, some things were easier to understand and pull off, some others more difficult. I have the impression than most WordPress developers are in the same situation. So I've been compiling my aha moments, and wrote a couple of articles for the LogRocket blog with…
Because Couchsurfing is dead , I requested to get all my data from the site, before having my account deleted. I just got the data: the images are resized down (they don't have the original dimensions I uploaded them with), and the data is a dull .json file, which does not reflect any of the personality, feelings or enjoyment that this same piece of data had in the site. It sucks. But at least,…
Bye bye Couchsurfing , you've been good to me, you've hosted me all over Europe and Japan, trips I couldn't have afforded otherwise. I met many friends. I met my wife. Those were good times. But that's no more. Couchsurfing (with a lowercase s) is dead. Today I logged-in to the website, and wherever I go, I can only access this screen: Mind you, if you're logged in, my profile is still available:…
In my latest article on LogRocket, Creating an @export GraphQL directive , I showed the screenshot of a GraphiQL client with red lines over the query argument definitions, which indicate there is an issue going on: Why is this happening? For the demonstration for my article, I have needed to print the value of the dynamic variable in the response, as to visualize that it works well. For that, I…
I have recently wrote 2 articles which, in general terms, accomplish the same objective: to show documentation to users of my plugin through a modal window in the WordPress admin. However, they use 2 different strategies: with and without Gutenberg. 🎩 Adding a Custom Welcome Guide to the WordPress Block Editor explains how to leverage the <Guide> component from Gutenberg: I required a few days of…
TL;DR: I published a new article on my GraphQL series: Treating GraphQL directives as middleware In the series on GraphQL I'm writing for LogRocket , I've been arguing that good support for custom directives may be the most important factor for choosing a GraphQL server. Motivated by this philosophy, I made the engine from GraphQL by PoP (my own implementation of a GraphQL server in PHP, soon to…
For my GraphQL API for WordPress plugin (to be released soon, yay!), I have created several Custom Post Types, which are elegantly operated through custom Gutenberg blocks. For instance, the GraphiQL block is used to create persisted GraphQL queries: Now, this block is not a content block, but a configuration block: it is used by the Custom Post Type called "GraphQL Persisted Query" to configure…
One of the issues with GraphQL is its lack of security: the single endpoint it provides can be accessed by anyone, legit users but also attackers trying to get private data, or attempt to bring the server down by sending complex queries. My upcoming GraphQL API for WordPress plugin offers a solution to this problem: it enables to create "persisted queries", where users can create/publish the query…
Not many articles (if any) comparing REST and GraphQL mention directives to be a key differentiator. Yet, I believe that directives are one of the most powerful features in GraphQL, which alone justifies migrating an API from REST to GraphQL. Coming from this realization, I wrote piece GraphQL directives are underrated to bring out all the beauty from directives: What are directives What different…
My laptop just broke, but I was lucky enough to be lent another laptop to keep working until I can have mine fixed. I didn't want to mess up this computer installing all the software I need to run my development web server (MAMP, MySQL, configuring hosts and virtual hosts, configuring php.ini , what PHP version to use, what WordPress, and so on), so this was the perfect chance to start using Lando…
The upcoming GraphQL API for WordPress plugin (to be released this May!) allows to create multiple GraphQL endpoints, each of them with a different configuration, as to expose only the require data, add a corresponding access control strategy, set-up specific cache max-age values, and others. For instance, we can create endpoints: /graphql/website /graphql/mobile-app /graphql/client-this-one…
The video for the sneak preview to my upcoming GraphQL API for WordPress plugin (to be released this May!) has been published: The quality of the video uploaded to YouTube is terrible though 😢, the videos are pretty much static. So in the upcoming days I'll link to each of the demoed videos, which I've uploaded to this channel in Vimeo . It will be 7 posts for 7 demoed functionalities: → Custom…
Gutenberg can help build better mobile apps (and other apps that need to consume data from our site), since it enables to cleanly identify and extract pieces of data (like images or videos) which can be referenced within the mobile app directly, instead of being lost within a soup of HTML. Combined with the WP REST API , every single piece of metadata in our site then becomes available. My plugin…
I just gave a sneak preview to my upcoming GraphQL API for WordPress plugin for CMS Philly (to be released this May!). I will share the video once it's ready. In the meantime, I share my beautiful slides:
A few weeks ago I had added the ability to independently version fields and directives in GraphQL by PoP, by passing the version constraint as a field/directive argument when executing the query. This works well but has a problem: that specific version of the schema could be accessed only by running the query, but not by introspection. So we couldn't run clients or tools against it. Today I have…
I have finally started working on the documentation site for GraphQL by PoP: https://graphql-by-pop.com This site is powered by VuePress , the Vue -centric static site generator for documentation. And it's soooo beautiful! I'm extremely pleased with the results so far. 😍 I have already completed the homepage and installation page. I'll keep working on the rest of the documentation during the…
I seem to be in a custom-directive-creation spree for GraphQL by PoP : 2 days ago I added directive @removeIfNull (as to be able to distinguish between null and omission values in the response), and today I created directives @cache and traceExecutionTime . Let's check them out. @cache directive The @cache directive enables to cache the result of a heavy-to-compute operation. The first time the…
Directives allow to implement those features which are not natively-supported by the GraphQL spec . Then, if any implementor has come up with a compelling way to address a problem, it may be decided to incorporate it into the spec. Being able to difference between null and omissions in the query response is a great example of a feature that can be tackled through directives. When retrieving data…
I just added support for another lovely new feature in GraphQL by PoP : the ability to independently version fields and directives, which can then be selected in the query through field/directive arguments. It is similar to how REST supports versioning, but extremely fine grained: instead of versioning the whole API, or the endpoint, what is versioned is a single field or directive, and a query…
When your PHP project uses the great Composer to manage dependencies, and it links to your own dependencies which are being concurrently developed, and you have the source code for these dependencies in your local drive, then you can speed up development time by pointing the project's dependencies to your local folders, as I described here . This strategy works great, however it has a problem:…
I just added support for a lovely new feature in GraphQL by PoP : the ability to execute mandatory directives whenever a specific field or directive is present in the GraphQL query. This means that the GraphQL engine will: Whenever a specific field from some type is present in the query, add a certain directive (or directives) to be executed on the field Whenever a specific directive is invoked,…
I wrote my third article for the LogRocket Blog , where I explain my journey on conceptualizing, designing and implementing a GraphQL server, as I have done for GraphQL by PoP : Code-first vs. schema-first development in GraphQL This article describes the 2 approaches to implementing a GraphQL server: Schema-first: we first define the schema for the GraphQL service using the Schema Definition…
I wrote my second article for the LogRocket Blog , where I explain my journey on conceptualizing, designing and implementing a GraphQL server, as I have done for GraphQL by PoP : “Don't think in graphs, think in components: Simplifying the GraphQL data model ” This article describes how the GraphQL server can use components as the data structure to represent the information (instead of using…
I wrote a guide on automating the launch of WordPress sites through Composer and WP-CLI for Design Bombs : Bootstrapping WordPress projects with Composer and WP-CLI Following the method I described in this guide, it literally takes seconds to launch a new WordPress site, making it ideal when we need to launch multiple instances of a site (DEV, STAGING, PROD) or when we produce WordPress sites for…