{"id":25687130,"url":"https://github.com/holyshared/moostrap","last_synced_at":"2026-06-12T06:31:19.608Z","repository":{"id":136708193,"uuid":"2322838","full_name":"holyshared/Moostrap","owner":"holyshared","description":"Moostrap offers the initialization function of large-scale application from middle-scale.","archived":false,"fork":false,"pushed_at":"2012-01-24T15:40:33.000Z","size":1644,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-10-07T01:58:19.126Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/holyshared.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2011-09-04T11:32:15.000Z","updated_at":"2013-02-14T08:08:32.000Z","dependencies_parsed_at":"2023-03-12T10:22:43.563Z","dependency_job_id":null,"html_url":"https://github.com/holyshared/Moostrap","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/holyshared/Moostrap","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/holyshared%2FMoostrap","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/holyshared%2FMoostrap/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/holyshared%2FMoostrap/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/holyshared%2FMoostrap/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/holyshared","download_url":"https://codeload.github.com/holyshared/Moostrap/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/holyshared%2FMoostrap/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34232789,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-12T02:00:06.859Z","response_time":109,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-02-24T20:08:11.814Z","updated_at":"2026-06-12T06:31:19.583Z","avatar_url":"https://github.com/holyshared.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\nMoostrap\n====================================\n\n![Moostrap](http://holyshared.github.com/Moostrap/images/logo.jpg \"Moostrap\")\n\n**Moostrap** offers the initialization function of large-scale application from middle-scale.  \nEvery one initialization processing is performed and it secures that initialization of application is ensured. \n\n![Moostrap package](http://holyshared.github.com/Moostrap/images/package_image.jpg?20120102 \"Moostrap package\")\n\n\nHow to use\n------------------------------------------------------------------------\n\n### 1. Creation of an initialization module\n\nIn order to use Moostrap, an initialization module is created first.  \nUsing **Moostrap.Module**, initialization processing is registered and it goes.  \n\nTwo or more registration is possible for initialization processing.  \n\nThe option at the time of execution and the processing to perform are specified.  \nWhen it succeeds in processing, **success** is performed, and **failure** is performed when it fails.  \n\n\n#### moostrap.js\n\n    (function(){\n\n        var Bootstrapper = this.Bootstrapper = new Moostrap.Module();\n\n        //Initialization processing is registered by the name of **bootstrapA**. \n        //A basic setup of application is performed.\n        Bootstrapper.register('bootstrapA', {\n\n\t\t\ttitle: 'bootstrapA',\n\n            configuration: {\n                name: 'bootstrap',\n                description: 'bootstrap description'\n            },\n\n            handler: function(app, opts){\n\n                try {\n                    app.setName(opts.name)\n                        .setDescription(opts.description);\n                } catch(exception) {\n                    this.failure();\n                }\n                this.success();\n\n            }\n\n        });\n\n        //Initialization processing is registered by the name of **bootstrapB**. \n        //The URL list of pictures is acquired using Ajax. \n        Bootstrapper.register('bootstrapB', {\n\n\t\t\ttitle: 'bootstrapB',\n\n            configuration: {\n                url: 'http://example.com/images/'\n            },\n\n            handler: function(app, opts){\n\n                var loader = new Request.JSON({\n                    url: opts.url,\n                    onSuccess: function(response){\n\n                        app.setImages(response.images);\n\n                        this.success();\n                    },\n                    onFailture: function(xhr){\n                        this.failure();\n                    }\n                });\n                loader.send();\n\n            }\n\n        });\n\n    }());\n\n\n### 2. An initialization module is used.\n\nApplication is initialized using the created module.\nAn **onSuccess event** will be generated if all initialization is performed.  \nIf processing goes wrong in the middle of initialization processing, processing is interrupted and execution of application is stopped.\n\n#### applicaton.js\n\n    (function(module){\n\n        var application = {\n\n            start: function(){\n\n                //do something\n\n            },\n\n            abort: function(){\n\n                //do something\n\n            },\n\n            run: function(){\n\n                var app = this;\n                var bootstrapper = new Moostrap('sync', module, {\n                    //A setup of an initialization module is specified.\n                    //A setup here carries out the override of the default setup.\n                    configurations: {\n\n                        //The override of the setup of bootstrapA is carried out.\n                        bootstrapA: {\n                            name: 'Hello world',\n                            description: 'My first application'\n                        },\n\n                        //The override of the setup of bootstrapB is carried out.\n                        bootstrapB: {\n                            url: 'http://helloworld.com/images/'\n                        }\n                    },\n                    onSuccess: app.start,\n                    onFailture: app.abort\n                });\n\n                //Application is started.\n                bootstrapper.execute(app);\n\n            }\n\n        };\n\n        application.run();\n\n    }(Bootstrapper));\n\n\nInitialization pattern\n------------------------------------------------------------------------\n\n### Synchronization\n\nThe initialization processing using **Moostrap.Executer.Sync** performs processings in order one by one.  \nInitialization processing is performed whenever one processing is completed.\n\n![Moostrap.Executer.Sync](http://holyshared.github.com/Mootstrap/images/bootstrap_sync_flow.jpg?20120102 \"Moostrap.Executer.Sync\")\n\n\n#### The method of building\n\npackager build Moostrap/Moostrap.Executer.Sync +use-only Moostrap \u003e moostrap-sync.js\n\n\n### Asynchronous\n\nThe initialization processing using **Moostrap.Executer.Async** performs processings in order one by one.  \nA synchronization is not taken at this time.\n\n![Moostrap.Executer.Async](http://holyshared.github.com/Mootstrap/images/bootstrap_async_flow.jpg?20120102 \"Moostrap.Executer.Async\")\n\n\n#### The method of building\n\npackager build Moostrap/Moostrap.Executer.Async +use-only Moostrap \u003e moostrap-async.js\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fholyshared%2Fmoostrap","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fholyshared%2Fmoostrap","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fholyshared%2Fmoostrap/lists"}