Last active
January 26, 2017 21:38
-
-
Save mttmccb/6cf0d997a1a75b65a1aad06b10a7cda2 to your computer and use it in GitHub Desktop.
Aurelia Slot
This file contains 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
<template> | |
<require from="./man-with-no-name"></require> | |
<require from="./western-extra"></require> | |
<man-with-no-name>Sometimes the dead can be more useful than the living.</man-with-no-name> | |
<western-extra> | |
<h1 slot="outfit">dead man's shoes</h1> | |
<h2 slot="weapon">rifle</h2> | |
</western-extra> | |
</template> |
This file contains 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
export class App { } |
This file contains 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
<!doctype html> | |
<html> | |
<head> | |
<title>Aurelia</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
</head> | |
<body aurelia-app> | |
<h1>Loading...</h1> | |
<script src="https://jdanyow.github.io/rjs-bundle/node_modules/requirejs/require.js"></script> | |
<script src="https://jdanyow.github.io/rjs-bundle/config.js"></script> | |
<script src="https://jdanyow.github.io/rjs-bundle/bundles/aurelia.js"></script> | |
<script src="https://jdanyow.github.io/rjs-bundle/bundles/babel.js"></script> | |
<script> | |
require(['aurelia-bootstrapper']); | |
</script> | |
</body> | |
</html> |
This file contains 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
.ManWithNoName { | |
border: 1px solid lightslategray; | |
border-radius: 1rem; | |
display: block; | |
padding: 1rem; | |
margin-bottom: 1rem; | |
} |
This file contains 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
<template class="ManWithNoName"> | |
<require from="man-with-no-name.css"></require> | |
<slot></slot> | |
</template> |
This file contains 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
export class ManWithNoName { } |
This file contains 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
.WesternExtra { | |
border: 1px solid lightslategray; | |
border-radius: 1rem; | |
display: block; | |
overflow: hidden; | |
margin-bottom: 1rem; | |
} | |
.WesternExtra-outfit { | |
background-color: darkgoldenrod; | |
border-bottom: 1px solid lightslategray; | |
color: white; | |
padding: 1rem; | |
} | |
.WesternExtra-weapon { | |
background-color: lightsteelblue; | |
padding: 1rem; | |
} |
This file contains 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
<template class="WesternExtra"> | |
<require from="western-extra.css"></require> | |
<header class="WesternExtra-outfit"> | |
<slot name="outfit"></slot> | |
</header> | |
<section class="WesternExtra-weapon"> | |
<slot name="weapon"></slot> | |
</section> | |
</template> |
This file contains 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
export class WesternExtra { } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment