Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stuck at step 3 setting up a new project #470

Closed
alexdufetel opened this issue Aug 24, 2016 · 4 comments
Closed

stuck at step 3 setting up a new project #470

alexdufetel opened this issue Aug 24, 2016 · 4 comments

Comments

@alexdufetel
Copy link

followed installation guide, created a new project, installed firebase and angularfire2, replaced the main.ts file with the one provided (and added the firebase config).

After that my app does not compile, I get multiple errors like this :
.../node_modules/angularfire2/angularfire2.d.ts:13:65
Cannot find namespace 'firebase'.

@dmastag
Copy link
Contributor

dmastag commented Aug 24, 2016

Had the Same problem on my Ionic App and had to revert to Beta.2.
What Angular RC version are you using?

@GitHubish
Copy link

GitHubish commented Aug 24, 2016

Same mistake here: Error with "ng build && ng serve" following "Installation and Setup" guide

The problem at the moment is not resolved at home. The additional step that was provided to us was to add firebase in tsconfig.json in array types and to update typescript in its latest version with the command:

npm install -g typescript@next
npm install typescript@next --save-dev

and tsconfig:

{
  "compilerOptions": {
    "declaration": false,
    "emitDecoratorMetadata": true,
    "experimentalDecorators": true,
    "lib": ["es6", "dom"],
    "mapRoot": "./",
    "module": "es6",
    "moduleResolution": "node",
    "outDir": "../dist/out-tsc",
    "sourceMap": true,
    "target": "es5",
    "typeRoots": [
      "../node_modules/@types"
    ],
    "types": [
      "jasmine",
      "firebase"
    ]
  }
}

But this raises worries on my side I now full of new errors . In case if it can help.

@cre8
Copy link

cre8 commented Aug 24, 2016

you can import firebase to the module file where you init angularfire
import * as firebase from 'firebase'

@alexdufetel
Copy link
Author

Thanks cre8, that solved the issue for me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants