DEV Community

artydev
artydev

Posted on • Updated on

What is your 'hello world' program in Javascript ? Use whatever library you want or not...

Here is mine :

import {print} from "./dml"; /* <sdtio.h> :-) */

print("Hello World");

Enter fullscreen mode Exit fullscreen mode

You can test it here : HelloWorld

Here is an extra, you can paste it in the demo.

import {print, hr, br, button} from "./dml"; /* <sdtio.h> :-) */

print("<center><h2>Hello World in Javascript & DML</h2></center>")

print("Hello World");

hr()
br()

function mail(name) {
  print(`Hello M. ${name}, we are proud to present you DML`);
  br()
  print('<span>Click here if you like it : </span>')
  let b = button("greet");
  b.onclick = () => alert("great");
}


mail("John") 
Enter fullscreen mode Exit fullscreen mode

Top comments (0)