-
Notifications
You must be signed in to change notification settings - Fork 793
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(runtime): do regular clone of normal slotting (#2694)
Co-Authored-By: Justus Romijn <[email protected]>
- Loading branch information
1 parent
e20c284
commit 602c1e2
Showing
7 changed files
with
416 additions
and
1 deletion.
There are no files selected for viewing
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
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
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import { Component, h, Host } from "@stencil/core"; | ||
|
||
@Component({ | ||
tag: "slot-ng-if", | ||
shadow: false, | ||
}) | ||
export class AngularSlotBinding { | ||
render() { | ||
return ( | ||
<Host> | ||
<slot /> | ||
</Host> | ||
); | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf8"> | ||
<script src="/assets/angular.min.js"></script> | ||
<script src="/build/testapp.esm.js" type="module"></script> | ||
<script src="/build/testapp.js" nomodule></script> | ||
<section id="demo">bla | ||
<section ng-controller="homeCtrl as vm"> | ||
<div ng-if="vm.show"> | ||
<slot-ng-if><span>{{vm.label}}</span></slot-ng-if> | ||
</div> | ||
</section> | ||
</section> | ||
<script> | ||
angular.module('demo', []).controller('homeCtrl', homeCtrl); | ||
function homeCtrl() { | ||
var vm = this; | ||
vm.label = 'Angular Bound Label'; | ||
vm.show = true; | ||
} | ||
angular.bootstrap(document.querySelector('#demo'), ['demo']); | ||
|
||
</script> |