[SOLVED] Making a default menu does not work


I tried the code exactly as the example in the docs, but nothing happens, and the resulting menu is blank:


What’s missing??


Figured it out. The code needs to be fired in the ready event, otherwise it does not work:

app.on( 'ready', () => {

	const menu = Menu.buildFromTemplate(template)


The docs didn’t mention it.