Created
July 17, 2017 04:37
-
-
Save wwwmarcos/360d41652d5be6f6c4f371923f5a0b42 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function() { | |
'use strict' | |
angular | |
.module('alabama', []) | |
.component('alabama', { | |
template: 'transclude.component.html', | |
controller: AlabamaComponentController, | |
transclude: { | |
'title': '?alabamaTitle', | |
'body': 'alabamaBody', | |
} | |
}) | |
function AlabamaComponentController() { | |
var $ctrl = this | |
} | |
})() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<alabama> | |
<alabama-title> | |
Wow, title | |
</alabama-title> | |
<alabama-body> | |
Lorem ipsum dolor | |
</alabama-body> | |
</alabama> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div data-ng-transclude="title"> | |
<h1>Fallback Title</h1> | |
</div> | |
<div data-ng-transclude="body" /> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment