{"id":24423172,"url":"https://github.com/webability-go/boxmodel","last_synced_at":"2026-04-20T20:36:52.326Z","repository":{"id":102393337,"uuid":"252588012","full_name":"webability-go/boxmodel","owner":"webability-go","description":"Data Flow Box Model","archived":false,"fork":false,"pushed_at":"2020-04-13T00:37:23.000Z","size":1,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-20T10:16:57.568Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","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/webability-go.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-04-02T23:35:54.000Z","updated_at":"2020-04-13T00:37:08.000Z","dependencies_parsed_at":"2023-03-13T15:20:13.678Z","dependency_job_id":null,"html_url":"https://github.com/webability-go/boxmodel","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webability-go%2Fboxmodel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webability-go%2Fboxmodel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webability-go%2Fboxmodel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webability-go%2Fboxmodel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/webability-go","download_url":"https://codeload.github.com/webability-go/boxmodel/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243420575,"owners_count":20288113,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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-01-20T10:17:01.793Z","updated_at":"2025-12-28T00:13:31.234Z","avatar_url":"https://github.com/webability-go.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# The Box Model\r\n\r\nThe box model is an intent to put back the programmation to where it belongs: the data.\r\nEvery piece of program is, by essence, a tool that will process some data. An input, a process and an output.\r\nEven every complex program can be fragmented into little pieces that will process data.\r\n\r\nUnfortunately, as today people and most programmers see programs as a piece of code, not as a tool to process data.\r\nThis is eventually one of the many causes of poor programmation, because people does not focus on the data, but on the code itself.\r\n\r\nSo lets change the focus, and rethink why we are programming.\r\nWe are building a set of many processes that will transform the data into something usefull, for humans, for another system, for machines, etc.\r\n\r\nUnderstanding the data flow is a way to master the code, and build it for this purpose.\r\n\r\nActually, when you start to fragment the data flow into simple tasks or processes, you rapidly become aware that many tasks are virtually the same, just with some few changes into the data.\r\n\r\nLets take a first simple example.\r\n\r\nA web page for an online catalog:\r\n\r\nLet say a user makes a request to a web server: Give me the \"first page\" of the category \"soap\" ordered by \"name\".\r\nThe request would take 3 parameters, page = 1, category = soap, order = name\r\nYou may have some config underlaying parameters, for instance products per page = 10, database connector (username, password, etc)\r\n\r\nThe system, after validating the parameters, will load the 10 products in memory, inject them to a template with a loop (for each product) and finally send the result back to the user.\r\n\r\nThe data will be transformed through black boxes ordered as a process.\r\n\r\nLets draw this simple example with detail:\r\n\r\nBOX 1: Load data from database.\r\nInput: page, category, order, database connector data, num per page\r\nOutput: List of objects (hierarchical structure, collection of records)\r\n\r\nBOX 2: Load a template from file\r\nParameter: the template resource (filename)\r\nOutput: The template\r\n\r\nBOX 3: Inject data into template.\r\nInput: any structure (BOX 1), the template (BOX 2)\r\nOutput: String of the armed html5 code\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebability-go%2Fboxmodel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwebability-go%2Fboxmodel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebability-go%2Fboxmodel/lists"}