The `mermaid.core.js` build was previously a UMD build that did not
have `node_modules` bundled.
This was designed for users to add `mermaid` to their own apps,
then bundle with Webpack/ESBuild.
Hence the bundle test in `cypress/platform/bundle-test.js`.
As ESBuild does not support UMD, I've switched the `mermaid.core.js`
to instead use ESM, as Mermaid now requires ESM
(due to d3 requiring ESM). All modern bundlers also support ESM.
When converting a `.jison` file into a CommonJS module,
jison by default adds a main() function that calls `require("fs");`
Even though the main function is never used in the browser,
because `fs` is a Node.JS only module, this causes some esbuild issues.
To disable this, we can just set an empty main to the jison generator.