JSFiddle - React, Tailwind, and code Playground

JavaScript

/* Module Code */
var MapModule = (function (module, $, global) {
    var $_address;
    var $_mapContainer;

    // Public functions

    function _loadApi() {
        // Do something, maybe load an API?
    }

    function _someInternalMethod() {
        // Do other things.
    }

    function _initialize = function () {
        _loadApi();
    }

    // Private functions

    function _setAddress = function (address) {
        $_address = address;
    };

    function _getAddress = function () {
        return $_address;
    };

    $.extend(module, {
        loadApi: _loadApi,
        someInternalMethod: _someInternalMethod,
        initialize: _initialize
    });

    return module;
})(MapModule || {}.this.jQuery, this);

// Usage
MapModule.initialize();