Skip to content

Commit 40d4459

Browse files
committed
fix(docs): system-config.ts setup (angular#154)
1 parent 16b0797 commit 40d4459

File tree

1 file changed

+14
-2
lines changed

1 file changed

+14
-2
lines changed

docs/1-install-and-setup.md

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,19 @@ Run a build and check the `/dist/vendor` folder for the `angularfire2` and `fire
7373
Open `/src/system-config.ts`. Modify the file like below:
7474

7575
```js
76-
// TODO: Find the actual way to do this
76+
/** Map relative paths to URLs. */
77+
const map: any = {
78+
'firebase': 'vendor/firebase/lib/firebase-web.js',
79+
'angularfire2': 'vendor/angularfire2'
80+
};
81+
82+
/** User packages configuration. */
83+
const packages: any = {
84+
angularfire2: {
85+
defaultExtension: 'js',
86+
main: 'angularfire2.js'
87+
}
88+
};
7789
```
7890

7991
AngularFire 2 and Firebase need to be mapped with System.js for module loading.
@@ -86,7 +98,7 @@ Open `/src/app.ts`, inject the Firebase providers, and specify your default Fire
8698
import { bootstrap } from '@angular/platform-browser-dynamic';
8799
import { enableProdMode } from '@angular/core';
88100
import { <MyApp>, environment } from './app/';
89-
import {FIREBASE_PROVIDERS, defaultFirebase, AngularFire} from 'angularfire2';
101+
import { FIREBASE_PROVIDERS, defaultFirebase } from 'angularfire2';
90102

91103
if (environment.production) {
92104
enableProdMode();

0 commit comments

Comments
 (0)