Domo.JS is not getting created via domo init

Domo.js is not getting deployed when I create a new project using domo init. I know there are workarounds to create this using

npm install --save ryuu.js

But I am wondering if this is a symptom for some systemic problem which is also causing my projects to error out with message such as these:

Best Answer

  • sourabh05
    sourabh05 Member
    Answer ✓

    Closing the loop on this one. I realize that the new method of initiating an app instance does not install domo.js on the project. But it links the library through CDN and the info can be found in the script tag.

    I ended up manually copying the domo.js file from another project to resolve that error. But at some

    later point I removed the manual files and ryuu package through CDN was sufficient to run the code. I cant tell you why it didn't work earlier. But hey the code eventually worked.

Answers

  • GET https://localhost:3000/domo.js net::ERR_ABORTED 404 (not found)

    This error indicates that the application is trying to load domo.js from localhost:3000, but the file does not exist, resulting in a 404 error. This is a key issue: domo.js is missing or not correctly deployed to your local server.

    Refused to execute script from 'http://localhost:3000/domo.js' because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled.

    This indicates that the server is returning an HTML response when trying to load domo.js. This likely means the server is serving a fallback HTML page (often a 404 page) instead of the actual JavaScript file. Because the MIME type is text/html instead of application/javascript, the browser refuses to execute the file.

    Unexpected end of JSON input at JSON.parse at index.js:6:22. This error is happening because the response returned from trying to fetch domo.js is not valid JSON (it's likely an HTML 404 page), and when the code tries to parse it as JSON, it throws an error because it's incomplete or incorrectly formatted.

    Check if domo.js is generated and deployed correctly. Re-run: domo init

    You could try updating the Domo CLI, manually install ryuu.js which is often used in conjunction with domo.js.

    ** Was this post helpful? Click Agree or Like below. **
    ** Did this solve your problem? Accept it as a solution! **

  • sourabh05
    sourabh05 Member
    edited October 24

    Thanks for your feedback @ArborRose.

    My issue is that domo init is not generating/deploying domo.js.

    I even tried to install it manually and it says 'up to date, audited 2 packages in 940ms. But when I check the folder, there's nothing.

  • sourabh05
    sourabh05 Member
    Answer ✓

    Closing the loop on this one. I realize that the new method of initiating an app instance does not install domo.js on the project. But it links the library through CDN and the info can be found in the script tag.

    I ended up manually copying the domo.js file from another project to resolve that error. But at some

    later point I removed the manual files and ryuu package through CDN was sufficient to run the code. I cant tell you why it didn't work earlier. But hey the code eventually worked.