helloworld

Hello World in Multiple Languages Extravaganza: Javascript

Hello world project extravaganza, the Javascript version.

Synopsis

This repository contains a collection of “Hello World” Javascript programs; from the simplest “Hello World” Javascript, in plain text, to a “Hello World” more complex. This is part of a fun and educational project that showcases how to print “Hello World” in different programming languages. The goal is to have a “Hello World” program in every programming language. This project is inspired by the GitHub Hello World project and you can found it in Hello World Extravaganza website.

check out the code

To get started, clone this repository to your local machine:

git clone https://github.com/silviotorre/helloworld.git

Getting Started

To run the “Hello World” program navigate to the project directory and run the program. Follow the instructions below to run the “Hello World” . Some info: JavaScript is a high-level, interpreted programming language primarily used for building interactive web applications. It enables dynamic behavior and interactivity on web pages through client-side scripting. JavaScript is one of the most popular programming languages in use on the World Wide Web but it can also be used in other environments. Note: there are many frameworks and libraries that use javascript, in this repo we work with plain javascript, also known as vanilla javascript, allowing developers to work directly with the core features and functionality of the language. Vanilla JavaScript is a fast, lightweight, and powerful tool so you don’t need something heavy, remember: “Lightsaber are for Jedi” (see https://vanillajstoolkit.com/). For general more information see https://en.wikipedia.org/wiki/JavaScript

alternatively you can:

Example


start hello-world.html

An advanced version of Javascript “Hello World” program

There is several design patterns and you could potentially use it together, even though they would typically be used in much more complex and specific scenarios. In this example we use the module pattern, the module pattern is a common JavaScript coding pattern. It’s generally well understood, but there are a number of advanced uses that have not gotten a lot of attention. Also we use Observer and Factory design patterns. The Observer pattern offers a subscription model in which objects subscribe to an event and get notified when the event occurs. This pattern is the cornerstone of event driven programming, including JavaScript. The Observer pattern facilitates good object-oriented design and promotes loose coupling. Objects don’t have to know a lot about each other to interact, but instead need only be concerned with the fact that the event they are subscribing to will trigger if applicable. This pattern is also key in the effective use of the Model-View-Controller (MVC) architectural pattern. The Factory pattern is another creational pattern concerned with the notion of creating objects. Where it differs from the other patterns in its category is that it doesn’t explicitly require us to use a constructor. Instead, a Factory can provide a generic interface for creating objects, where we can specify the type of factory object we wish to be created.

tasks

Extra Credit

Contributing

Feel free to contribute your own “Hello World” programs to this repository. Simply create a new directory with the name of the programming language and add a file named hello-world. with your implementation. Don't forget to update the README file to include your contribution!

Contributors

License

References

Home of this project

Enjoy and happy coding!