Forum Discussion

Gaurav Goyal's avatar
Gaurav Goyal
Brass Contributor
Feb 11, 2018

SharePoint Framework and Angular 4/5 with multiple webparts

Hi,
I am trying to create SPFx multiple web parts with Angular 4. I have created 'App' folder under webparts folder and trying to run the project. I am able to run first web part but when adding second webpart , It is throwing errors.

I am attaching my code here.
Can you please suggest, How can I use angular 4 with only one app folder in SPFx with multiple webparts?

Thanks,
Gaurav


  • English1080's avatar
    English1080
    Copper Contributor

    i also face exact issue in spfx web part. i am searching the solution ofr this. if you got the solution for this issue please share answer with me. following are packages : 

     "@angular/animations": "~4.0.0",
        "@angular/common": "~4.0.0",
        "@angular/compiler": "~4.0.0",
        "@angular/core": "~4.0.0",
        "@angular/forms": "~4.0.0",
        "@angular/http": "~4.0.0",
        "@angular/platform-browser": "~4.0.0",
        "@angular/platform-browser-dynamic": "~4.0.0",
        "@angular/router": "~4.0.0",
        "@microsoft/sp-core-library": "1.9.1",
        "@microsoft/sp-lodash-subset": "1.9.1",
        "@microsoft/sp-office-ui-fabric-core": "1.9.1",
        "@microsoft/sp-webpart-base": "1.9.1",
        "@types/es6-promise": "0.0.33",
        "@types/webpack-env": "1.13.1",
        "classlist.js": "^1.1.20150312",
        "lodash": "^4.17.4",
        "reflect-metadata": "0.1.10",
        "rxjs": "~5.0.1",
        "systemjs": "0.19.40",
        "typescript-string-operations": "~1.1.0",
        "typings": "^2.1.1",
        "zone.js": "~0.8.4"

Resources