{"id":130505,"date":"2023-09-29T08:00:00","date_gmt":"2023-09-29T08:00:00","guid":{"rendered":"https:\/\/www.weixiaoduo.com\/plugins\/2024\/02\/22\/playground-embedder\/"},"modified":"2023-10-14T22:48:00","modified_gmt":"2023-10-14T22:48:00","slug":"playground-embedder","status":"publish","type":"post","link":"https:\/\/www.weixiaoduo.com\/plugins\/playground-embedder\/","title":{"rendered":"Playground Embedder"},"content":{"rendered":"<p>Add the WordPress playground by adding a <code>[wp_playground]<\/code> shortcode to your pages. This plugin supports all the attributes the playground supports, which <a href=\"https:\/\/wordpress.github.io\/wordpress-playground\/docs\/query-api#available-options\" rel=\"nofollow ugc\">you can find here<\/a>.<\/p>\n<p>By default, the plugin lazy loads the playground, so it\u2019s only loaded after a button click. An additional feature is that you<br \/>\ncan decide not to lazy load the playground by adding <code>lazy=0<\/code> to the shortcode, like so:<\/p>\n<pre><code>[wp_playground lazy=0]\n<\/code><\/pre>\n<p>At this point the plugin renders the playground immediately.<\/p>\n<h3>Blueprints<\/h3>\n<p>You can load entire blueprints into the shortcode by putting them in the content between the shortcode, like this:<\/p>\n<pre><code>[wp_playground]\n{\n    \"landingPage\": \"\/wp-admin\/\",\n    \"preferredVersions\": {\n        \"php\": \"8.0\",\n        \"wp\": \"latest\"\n    },\n    \"steps\": [\n        {\n            \"step\": \"login\",\n            \"username\": \"admin\",\n            \"password\": \"password\"\n        }\n    ]\n}\n[\/wp_playground]\n<\/code><\/pre>\n<p>These blueprints allow you to install themes, plugins and more. To learn about them, read the <a href=\"https:\/\/wordpress.github.io\/wordpress-playground\/blueprints-api\/index\" rel=\"nofollow ugc\">Playground documentation<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Embeds the WordPress playground through a shortcode.<\/p>\n","protected":false},"author":65,"featured_media":323275,"comment_status":"open","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"slim_seo":{"title":"Playground Embedder - \u8587\u6653\u6735\u63d2\u4ef6\u76ee\u5f55","description":"Embeds the WordPress playground through a shortcode."},"footnotes":""},"categories":[1],"tags":[],"class_list":["post-130505","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/posts\/130505","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/users\/65"}],"replies":[{"embeddable":true,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/comments?post=130505"}],"version-history":[{"count":0,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/posts\/130505\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/media\/323275"}],"wp:attachment":[{"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/media?parent=130505"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/categories?post=130505"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/tags?post=130505"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}