Add javascript singleton example