Block Development: hamburger module throwing error in save function

This is because you’ve put interactive components inside your save component, which is forbidden.

A save components job is to generate raw HTML strings that get saved in the database. It does this in the editor in javascript, save components never run on the frontend, and there is no way to “save” an interactive or react component.

At the end of the day the block editor saves HTML and HTML comments, not React components.

To fix this, you will need to render save components that are static and not interactive, no state/reducers/stores/context/event hooks/etc. Then, enqueue JS for the frontend that either turns it into a hamburger menu or replaces it. You can use the hamburger component from netlify in this frontend JS file

Note that this is specifically for the save component. Frontend JS and your edit component etc can use state/etc just fine.