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
/*global _:false */ | |
'use strict'; | |
angular.module('PubSubEngineModule') | |
.factory('PubSubEngine', ['$q', '$rootScope', | |
function($q, $rootScope) { | |
var PubSubEngine = {}; |
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
'use strict'; | |
/** | |
* @ngdoc service | |
* @name ObserverModule:ObserverService | |
* @description | |
* # ObserverService | |
* Manages all events inside the application | |
* | |
*/ |
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
@NgModule({ | |
imports: [BrowserModule], | |
declarations: [HelloComponent], | |
entryComponents: [HelloComponent] | |
}) | |
export class HelloModule { | |
ngDoBootstrap() {} | |
} |
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
registerAsCustomElements([HelloComponent], () => | |
platformBrowserDynamic().bootstrapModule(HelloModule) | |
); |
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 lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Angular Elements Demo</title> | |
</head> | |
<body> | |
<hello-world name="Anna"></hello-world> |
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
@Component({ | |
selector: 'hello-world', | |
template: `<h1> | |
Hello world ! My name is {{name}} ! | |
</h1> | |
<button (click)="onClick()">Hi !</button>`, | |
styles: [` | |
button { | |
color: #3498db; | |
} |
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
/* global module */ | |
const AotPlugin = require('@ngtools/webpack').AngularCompilerPlugin; | |
const CompressionPlugin = require("compression-webpack-plugin"); | |
const path = require('path'); | |
module.exports = { | |
entry: './src/main.ts', | |
resolve: { | |
mainFields: ['es2015', 'browser', 'module', 'main'] | |
}, |