Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-13728

Types are not loaded into angular typescript project

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Cannot Reproduce
    • cordova-android-7.0.0
    • None
    • cordova-plugin-camera
    • None
    • MacOS High Sierra
      npm -v
      5.6.0

      node -v
      v8.4.0

      typescript 2.5.3

    Description

      When installing cordova-plugin-camera package via npm, types are not properly loaded in angular2 application:

      When trying to build or serve receiving such error:

      ERROR in error TS2688: Cannot find type definition file for '.github'.
      error TS2688: Cannot find type definition file for 'appium-tests'.
      error TS2688: Cannot find type definition file for 'doc'.
      error TS2688: Cannot find type definition file for 'jsdoc2md'.
      error TS2688: Cannot find type definition file for 'src'.
      error TS2688: Cannot find type definition file for 'tests'.
      error TS2688: Cannot find type definition file for 'www'.
      src/app/components/myprofile/photo-upload-modal/photo-upload-modal.component.ts(26,19): error TS2339: Property 'camera' does not exist on type 'Navigator'.
      src/app/components/myprofile/photo-upload-modal/photo-upload-modal.component.ts(29,69): error TS2304: Cannot find name 'Camera'.
      src/app/components/myprofile/photo-upload-modal/photo-upload-modal.component.ts(29,103): error TS2304: Cannot find name 'Camera'.
      src/app/components/myprofile/photo-upload-modal/photo-upload-modal.component.ts(31,29): error TS2304: Cannot find name 'Camera'.

      Attachments

        Activity

          People

            Unassigned Unassigned
            dmitriydementor Dmitriy
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: