{"id":15588436,"url":"https://github.com/solnic/lotuskase","last_synced_at":"2025-04-24T05:02:13.372Z","repository":{"id":66168159,"uuid":"48624434","full_name":"solnic/lotuskase","owner":"solnic","description":"Custom web stack based on dry-component and lotus","archived":false,"fork":false,"pushed_at":"2015-12-28T16:31:00.000Z","size":12,"stargazers_count":8,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-30T07:11:12.304Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","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/solnic.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":"2015-12-26T21:45:33.000Z","updated_at":"2020-02-29T10:57:40.000Z","dependencies_parsed_at":"2023-02-20T00:00:49.120Z","dependency_job_id":null,"html_url":"https://github.com/solnic/lotuskase","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/solnic%2Flotuskase","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/solnic%2Flotuskase/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/solnic%2Flotuskase/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/solnic%2Flotuskase/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/solnic","download_url":"https://codeload.github.com/solnic/lotuskase/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250566453,"owners_count":21451230,"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":"2024-10-02T22:40:19.947Z","updated_at":"2025-04-24T05:02:13.244Z","avatar_url":"https://github.com/solnic.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# lotuskase\n\nThis is a simple PoC that shows how [dry-component](https://github.com/dryrb/dry-component)\ncan be used to build a web stack using [lotus](https://github.com/lotus) components.\n\nBy no means it is a project that tries to compete with [the lotus stack](https://github.com/lotus/lotus).\nThe purpose of the project is to present how dry-component API can be used to organize\n3rd party code and how simple it is to put together a custom stack using reusable\ncomponents.\n\n## Why?\n\nTo make sure `dry-component` can be used with different setups, not just [rodakase](https://github.com/solnic/rodakase)\nfrom which it was extracted from.\n\n## What is it doing?\n\nThis is a lotus setup which uses dry-component container to configure and boot\nlotus routes, controllers and views.\n\nCode organization is minimalistic:\n\n- `core/blog/application` defines a simple rack-compatible app which delegates to its\n  lotus routes\n- `core/blog/container` configures the container for the blog application\n- `core/blog/view` uses dry-component boot API to configure and load lotus view\n- `core/blog/controller` uses dry-component boot API to configure and load lotus controller\n- `core/boot` loads the container and application\n- `web/routes` defines routes for the blog application\n\nThe rest levarages lotus conventions for controllers and views, so no special setup\nis needed and things Just Work™.\n\nWith dry-component each piece can be loaded separately and the container is the\nstarting point which configures load path and additional settings like the env.\nThis means you can, for example, open console and boot the view component:\n\n```\nirb(main):001:0\u003e require './core/blog/container'\n=\u003e true\nirb(main):002:0\u003e Blog::Container.boot!(:view)\n=\u003e Blog::Container\nirb(main):003:0\u003e Views::Home::Hello.render(format: :html)\n=\u003e \"\u003ch1\u003eHello World\u003c/h1\u003e\"\n```\n\nThis functionality is being used by the test setup, where spec_helper.rb only\nrequires the container and configures rspec. Then a separate `app_helper.rb`\nis used which loads `core/boot` where we load entire app that is needed for request\nspecs.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsolnic%2Flotuskase","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsolnic%2Flotuskase","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsolnic%2Flotuskase/lists"}