Search code examples
google-apps-scriptweb-applicationsalert

Alert shows lots of unnecessary information


I use google script and I call alert. It runs, but alert shows lots of unnecessary information. How can I clear unnecessary information?

code:

alert("Update "+ name + " successfully!");

I want to delete the red mark:

alert screenshot


Solution

  • This is browser specific text that cannot be altered. Try making a custom alert on your own if you really don't need this text.

    For example - https://sweetalert2.github.io/

    You can also Google to find more custom alerts and choose the right one for your project.