MV How can I get event comment in JavaScript?

I want to do different things by judging different comments.
(This does not mean note, but the event page of comments)
Depends on where do you want to access it, but the event comment has command code 108 and 408. The code stored in the event command list. If you want to access the event command list through the console window, you can do this.
JavaScript:
$gameMap.events()[x].page().list
Then filter the code, look for 108 and 408. They are the event comments.

Original thread: https://forums.rpgmakerweb.com/threads/how-can-i-get-event-comment-in-javascript.133137/