You probably shouldn’t use jQuery
with gutenberg block-editor. Instead, use api access like:
wp.data.select("core").XXXXXXX()
wp.data.select("core/editor").XXXXXXX()
where you should replace xxx
with desired functions. You can list them with console.log(wp.blocks.getBlockTypes());
while on block-editor page.
Related Posts:
- ajaxurl not defined on front end
- How to add a javascript snippet to the footer that requires jQuery
- How to include jQuery and JavaScript files correctly?
- How Do I Use jQuery UI In My Plugin
- How to use PanelColorSettings in custom Gutenberg block?
- Test to see if jQuery or Prototype is queued by another plugin?
- jQuery in header or footer
- Hook the Keydown Event in the TinyMCE Post Editor
- Adding pre-publish checks with Gutenberg
- Managing two editable fields in gutenberg
- How to make repeated component/block in Gutenberg
- Using Primary Color in Plugin Block
- Gutenberg ServerSideRender is deprecated, how to work with new wp.serverSideRender component?
- Add a jQuery function to admin pages
- How to get data from WordPress $wpdb into React Gutenberg Blocks Frontend?
- lodash dependency in a Gutenberg plugin
- Help adding image upload functionality to widget
- What’s the Right Way to get and save remote data for a Gutenberg block?
- Using Ajax call in jQuery doesn’t work in widget
- Error : “Updating failed: The response is not a valid JSON response” with custom shortcode
- How to disable “Transform to” option in Gutenberg custom blocks
- Ajax in WordPress – path issue
- Gutenberg: useDispatch is not a function – @wordpress/data included
- Make a list with header and subtext in Gutenberg blocks
- Loading jQuery and jQuery plugin script files correctly [duplicate]
- How insert negative values in Gutenberg box-control
- Initial help with official “create a block” tutorial
- Are block templates incompatible with serialize_blocks?
- How do I dynamically render an InnerBlock inside a dynamic block?
- ServerSideRender and Media Object: attributes passing image data object to php renderer even though it’s not set
- WordPress Block Development – trouble importing from @wordpress/icons
- Gutenberg blocks not getting styled on back end
- Run code once when block is created
- Best way to save custom css for an block
- How to insert text at the current cursor position in Gutenberg?
- How can I listen to events in Gutenberg block?
- It’s possible to passing a ref to FormTokenField from parent component using forwardRef?
- how to search users by ajax live search
- JSX in WordPress Plugin Development
- ResizableBox with RangeControl not working
- Gutenberg: import dependency or assign from global variable?
- javascript datatables in a plugin
- Hide shortcodes “code” when using the “editor” the same as wordpress do with “gallery”
- Gutenberg table block with Bootstrap .table class
- jquery & ajax sending data to php
- should i be checking for jquery before enqueing it in a plugin
- jQuery instantly executes (a button click and css change) on load
- how to get the post id in plugin
- Catching Gutenberg sidebar switch event
- Use npm and wp-env to make production bundle
- How to add template colors to custom block options in WordPress Gutenberg editor sidebar?
- Ajax: Populate with content from a post’s ID not working – duplicating current page html instead
- How to use apiFetch to get author information in Gutenberg properly?
- Gutenberg blocks error: Each child in a list should have a unique “key” prop
- How to properly package a block plugin
- Setting global block attribute value
- jquery in wordpress plugin with depdendency
- Gutenberg – is it ok to load dependencies multiple times?
- Preventing double loading JS scripts (like React) when developing for Gutenberg
- ajax working when function is on child theme but not in plugin page
- Ajax +wordpress onClick link redirect to new page and create html content
- Use options to control jQuery plugin
- How to localize data array in plugin’s option page
- sanitizing/escaping plugin options
- Using jQuery prepend() with file include
- Custom Block Not Shown in Block Inserter
- Ajax on the Administration Side of plugin – returns 0
- var(–text-color) in style.scss works once but not twitch
- Query String Filtering API
- Gutenberg block breaks when showing new data
- What happens/fires when you select a block in the editor?
- How to re-render inspector controls?
- jQueryUI draggable doesn’t work in WordPress plugin
- Get value of custom checkbox from Gutenberg sidebar in plugin
- Where to save Gutenberg plugin data?
- WordPress Jquery with heade and footer sritp plugin
- Gutenberg component in a plugin admin
- Add custom html classes to gutenberg wrapper
- Filterable posts using categories
- How to get values from Tinymce visual editor popup?
- WordPress function is not called and ajax return 0
- Ajax call not working with
- Script work on non logged in user but not work for logged in user?
- Page reload occurs before request finishes
- Custom plugin not appearing
- Gutenberg’s Popover component position relative to the focused element
- How to get the value entered in the input field in wordpres
- Gutenberg: – Call a function after Server Side Component is rendered
- Accept only PDF file for upload
- Help interpreting @wordpress/create-block-tutorial-template usage error
- How can I add a custom button to the post editor?
- How to get custom user meta by id in custom Gutenberg block
- Block Development: hamburger module throwing error in save function
- How to access Elementor-navigation-elements via jQuery
- Insert meta-description into Yoast-SEO input-field via JavaScript
- Adding a navigation with wp_nav_menu() to a custom block in the site editor
- Why isn’t custom sidebar panel not showing up in the Gutenberg Editor?
- REST API error in block editor for custom templates
- How can I include React useState in a custom gutenberg block plugin?
- Set srcset on a block image