Testing out the WP Playground Interactive Code Block

So if you attended the final keynote at WCEU you would have seen the WP Playground demo video.

I’ve been following WP Playground for some time now, and I was able to meet with the developer behind the project, Adam Zieliński, who showed me the interactive code block, which I had to try out.

Below is the simplest implementation of the block:

Loading interactive code snippet…

What I love about it is that it works like this whether you’re writing in the editor or displaying the code on the front end. So I can test this code and see what it will do before I publish this post.

As far as I can see, it supports anything that PHP supports, even working with classes, and setting types for function or method parameters.

Loading interactive code snippet…

How I wish I had this functionality when I first started blogging about learning PHP!


Posted

in

by

Tags:

Comments

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: