{"id":26068374,"url":"https://github.com/minutebase/ember-portal","last_synced_at":"2025-10-07T14:11:14.846Z","repository":{"id":33543324,"uuid":"37189462","full_name":"minutebase/ember-portal","owner":"minutebase","description":"Render stuff here, put it over there","archived":false,"fork":false,"pushed_at":"2018-10-08T15:11:47.000Z","size":961,"stargazers_count":8,"open_issues_count":10,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-11T18:07:01.922Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://minutebase.github.io/ember-portal","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/minutebase.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-06-10T10:00:04.000Z","updated_at":"2023-09-11T18:23:45.000Z","dependencies_parsed_at":"2022-08-07T22:00:44.874Z","dependency_job_id":null,"html_url":"https://github.com/minutebase/ember-portal","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/minutebase%2Fember-portal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/minutebase%2Fember-portal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/minutebase%2Fember-portal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/minutebase%2Fember-portal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/minutebase","download_url":"https://codeload.github.com/minutebase/ember-portal/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248456370,"owners_count":21106603,"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-03-08T22:25:25.736Z","updated_at":"2025-10-07T14:11:07.146Z","avatar_url":"https://github.com/minutebase.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Ember-portal\n\nRender stuff here, put it over there.\n\n[Demo](http://minutebase.github.io/ember-portal)\n\n![ember-portal in action](https://raw.githubusercontent.com/minutebase/ember-portal/master/demo.gif)\n\n## Installation\n\n```\nember install ember-portal\n```\n\n## Basic Usage\n\nSetup some portals in your application template, or wherever:\n\n```hbs\n{{! app/templates/application.hbs }}\n\n\u003cdiv class=\"header\"\u003e\n  {{portal-for name=\"header\"}}\n\u003c/div\u003e\n\n\u003cdiv class=\"content\"\u003e\n  {{outlet}}\n\u003c/div\u003e\n\n\u003cdiv class=\"footer\"\u003e\n  {{portal-for name=\"footer\"}}\n\u003c/div\u003e\n```\n\nThese will be empty until you give them some content from some other template:\n\n```hbs\n{{! app/templates/foo.hbs }}\n\n{{#portal-content for=\"header\"}}\n  This will appear in the header\n{{/portal-content}}\n```\n\nIf you render to the same portal in a deeper template, it will replace the\nprevious content:\n\n```hbs\n{{! app/templates/foo/bar/baz.hbs }}\n\n{{#portal-content for=\"header\"}}\n  This will replace the header content\n{{/portal-content}}\n```\n\n## DOM Layout\n\nember-portal uses [ember-wormhole](https://github.com/yapplabs/ember-wormhole) and manages the DOM element it needs to render the child elements into.\n\nGiven the following template:\n\n```hbs\n\u003cdiv class=\"header\"\u003e\n  {{portal-for name=\"header\"}}\n\u003c/div\u003e\n\n{{#portal-content for=\"header\"}}\n  \u003cdiv class=\"content\"\u003ethe content\u003c/div\u003e\n{{/portal-content}}\n```\n\nIt will result in the following HTML:\n\n```html\n\u003cdiv class=\"header\"\u003e\n  \u003cdiv class=\"ember-view\"\u003e \u003c!-- {{portal-for component}} --\u003e\n    \u003cdiv id=\"ember-portal--header\"\u003e \u003c!-- ember-wormhole container --\u003e\n      \u003cdiv class=\"content\"\u003ethe content\u003c/div\u003e \u003c!-- the content --\u003e\n    \u003c/div\u003e\n  \u003c/div\u003e\n\u003c/div\u003e\n```\n\nThe `{{portal-for}}` component takes `class` and `portal-class` attributes to add class names for styling, for example:\n\n```hbs\n\u003cdiv class=\"header\"\u003e\n  {{portal-for name=\"header\" class=\"header-outer\" portal-class=\"header-inner\"}}\n\u003c/div\u003e\n\n{{#portal-content for=\"header\"}}\n  \u003cdiv class=\"content\"\u003ethe content\u003c/div\u003e\n{{/portal-content}}\n```\n\nIt will result in the following HTML:\n\n```html\n\u003cdiv class=\"header\"\u003e\n  \u003cdiv class=\"ember-view header-outer\"\u003e \u003c!-- {{portal-for component}} --\u003e\n    \u003cdiv id=\"ember-portal--header\" class=\"header-inner\"\u003e \u003c!-- ember-wormhole container --\u003e\n      \u003cdiv class=\"content\"\u003ethe content\u003c/div\u003e \u003c!-- the content --\u003e\n    \u003c/div\u003e\n  \u003c/div\u003e\n\u003c/div\u003e\n```\n\n## Developing\n\n### Installation\n\n* `git clone` this repository\n* `npm install`\n* `bower install`\n\n### Running\n\n* `ember server`\n* Visit your app at http://localhost:4200.\n\n### Running Tests\n\n* `ember test`\n* `ember test --server`\n\n### Building\n\n* `ember build`\n\nFor more information on using ember-cli, visit [http://www.ember-cli.com/](http://www.ember-cli.com/).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fminutebase%2Fember-portal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fminutebase%2Fember-portal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fminutebase%2Fember-portal/lists"}