TransferState provides a shared store that is transferred from the server to client. To use it import BrowserTransferStateModule from the client app module and ServerTransferStateModule from the server app module and TransferState will be available as an Injectable object. PR Close #19134
		
			
				
	
	
		
			20 lines
		
	
	
		
			576 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			20 lines
		
	
	
		
			576 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
| /**
 | |
|  * @license
 | |
|  * Copyright Google Inc. All Rights Reserved.
 | |
|  *
 | |
|  * Use of this source code is governed by an MIT-style license that can be
 | |
|  * found in the LICENSE file at https://angular.io/license
 | |
|  */
 | |
| 
 | |
| const path = require('path');
 | |
| 
 | |
| module.exports = {
 | |
|   entry: {
 | |
|     helloworld: './built/src/helloworld/client.js',
 | |
|     transferstate: './built/src/transferstate/client.js',
 | |
|   },
 | |
|   output: {path: path.join(__dirname, 'built'), filename: '[name]-bundle.js'},
 | |
|   module: {loaders: [{test: /\.js$/, loader: 'babel-loader?presets[]=es2015'}]},
 | |
|   resolve: {extensions: ['.js']}
 | |
| };
 |