Forum Replies Created
-
AuthorPosts
-
Zac Gordon
KeymasterGlad you figured it out!
Yes, advanced examples do not exist too much. If you have specific questions please ask, but basically whatever data type you need, you can set an attribute for just as you would a normal variable in JS.
Zac Gordon
KeymasterHi! Can you upload a more clear screenshot of the error? Its a little too blurry to read 🙂
Zac Gordon
KeymasterJust want to double check first you understand from the course why this happens. It is generally bc we have made changes to the block code. When testing blocks it is easiest to delete the block and re add it.
For updating existing blocks, either use dynamic blocks or the deprecated feature.
Hope this helps in the right direction!
Zac Gordon
KeymasterThis should help 🙂
https://stackoverflow.com/questions/21154510/the-use-of-the-triple-exclamation-mark
Zac Gordon
KeymasterYou want to look into the formatting API for this I believe then 🙂
https://developer.wordpress.org/block-editor/tutorials/format-api/
Zac Gordon
KeymasterWhat is it exactly you’re trying to style?
Zac Gordon
KeymasterHi, yes, we keep the course up to date, so start anytime! We continue to add to the course and have a new version in the works we hope to release soon. Most of the requests have been added that made sense. We also released an Advanced Gutenberg Development Course that addressed several things as well I would highly recommend.
Zac Gordon
KeymasterHi!
Great question. To do this the official way you would use the deprecated property explained in the docs here – https://developer.wordpress.org/block-editor/developers/block-api/block-deprecation/
We will be covering this in an updated version of the course coming soon.
The other approach is to make all your blocks dynamic with PHP.
Zac Gordon
KeymasterThis article may help
https://javascriptforwp.com/adding-react-to-a-wordpress-theme-tutorial/
Zac Gordon
KeymasterHi!
I did not use this in the intro course, but did in the advanced one. It is used for registering blocks on the PHP/Server side. This is not required, but there are benefits to doing so.
Zac Gordon
KeymasterGlad you got it sorted! Thanks for sharing the solution 🙂
Zac Gordon
KeymasterOkay, see where you’re running. I tried duplicating the issue on my end and wasn’t able to to.
Do any of the other React exercise folders work for you?
Zac Gordon
KeymasterHi! What folder are you running this command in?
December 5, 2019 at 3:43 pm in reply to: Git can not be recognised by Visual Studio Code and Windows Cmd #127608Zac Gordon
KeymasterSupport is for active members and folks who have purchased courses, just waiting to verify your membership status. Thanks for understanding!
December 5, 2019 at 12:27 pm in reply to: Git can not be recognised by Visual Studio Code and Windows Cmd #127562Zac Gordon
KeymasterOkay, I am not too sure with the specific error you have or setup you are doing with Git.
However, to start with a basic test, what happens when you try to simply clone a git repository? Does that work?
Zac Gordon
KeymasterMy starting point would be comparing your markup to the markup in the image examples from the course. It may be that something extra is added or missing. If you would like to share the plugin code would be happy to take a look 🙂
November 24, 2019 at 7:44 pm in reply to: Dynamic block get posts by category with a way to change category #125163Zac Gordon
KeymasterGlad you figured it out!
Zac Gordon
KeymasterI looked at both Netlify and Formspree for the Gatstby Basics Course.
Netlify looks good but you have to use their servers and doesn’t currently really work locally. Formspree is a bit easier to test, but not a fan of some of the features.
I’m going to be showing how to do this with WordPress and native WordPress form plugins in my Gatsby and WordPress course.
However, if you want to do this completely on your own this might help you setup something simple:
https://www.gatsbyjs.org/docs/building-a-contact-form/#run-your-own-server
Integrating with something like Sendgrid might be a better solution.
You’ll want to make sure your hosting for the Gatsby site can run a PHP form handler, and in general switching to a JS driven one might be a better match overall.
Hope that helps a bit!
October 4, 2019 at 3:28 pm in reply to: How to develop a GutenberBlock and a Front-end React Component at the same time. #119560Zac Gordon
KeymasterHi! Have you checked out the related section in the Advanced Gutenberg Course? I would suggest starting with that and discussions of sharing components on the front and back end.
September 9, 2019 at 5:19 pm in reply to: Gatsby Basics: gatsby-mdx is depreciated, use gatsby-plugin-mdx instead #117589Zac Gordon
KeymasterThanks for the ping! Actually update this in a later video, but will link to this from the video!
Zac Gordon
KeymasterOkay, the first thing I want to check is if you just hardcode the value of the options attribute to the page, is that changing when you select different values? Before testing the media part of this, want to make sure _some_ change is happening when you change the dropdown.
Can you please share the code you are using for updating the attribute value when the dropdown changes?
Zac Gordon
KeymasterOkay, first thing I want to check is that this isn’t due to a missing babel config setup. If you just return some very simple React, like a p tag with text does it work or give the same error. Also, depending on what Boilerplate you started with, do you have a .babelrc file?
August 29, 2019 at 2:51 pm in reply to: Inspector Control Field Issues in Gutenberg Block Dev Course #116315Zac Gordon
KeymasterThanks for finding this Laine! I posted an update to the repo that should work now.
Basically I added a few lines to sort the object alphabetically before displaying it each time to avoid the issue 🙂
Can see the specific fix here:
https://github.com/zgordon/gutenberg-course/blob/bc3dbbe20b72c3cf24ff767650ae0d0271cfae4f/blocks/07-inspector-control-fields/index.js#L15-L25Let me know if you have further issues! I will add a note to the video with this thread 🙂
August 29, 2019 at 2:33 pm in reply to: Inspector Control Field Issues in Gutenberg Block Dev Course #116314Zac Gordon
KeymasterThanks Laine! Confirming I’m seeing this too now, looking at a fix 🙂
Zac Gordon
KeymasterHi! Sorry for the delay here, but the bundled JS does not include the components, those are loaded by WordPress itself. The build size shouldn’t change too much by adding more blocks.
What will be included are any packages you are loading that are not dev dependencies. You can also make sure that you are running npm run build instead of dev as it will optimize things a bit more.
Hope that helps!
-
AuthorPosts