<!DOCTYPE html>
<html>

<head>
        <link rel="stylesheet" href="style.css" />
        <script src="https://code.angularjs.org/2.0.0-alpha.31/angular2.sfx.dev.js"></script>
        <script>
                function Service() {};
                
                Service.prototype.greeting = function() {
                        return 'Hello';
                };

                var v1 = ng.Component({
                        selector: 'anil',
                        viewInjector: [Service]
                }).
                View({
                        template: '{{greeting}} Anil!'
                }).
                Class({
                        constructor: [Service, function v1(service) {
                                this.greeting = service.greeting();
                        }]
                });

                document.addEventListener('DOMContentLoaded', function() {
                        ng.bootstrap(v1);
                });
        </script>
</head>

<body>
        <anil></anil>
        <a href="http://www.code-sample.com/">For more..</a>
</body>

</html>
/* Styles go here */