From 1589845ccb7cebbbc8546ddaf0ab2be5543059a8 Mon Sep 17 00:00:00 2001 From: Sebastian Lange Date: Thu, 24 Jan 2019 14:09:47 +0100 Subject: [PATCH] docs: update and translate PITFALLS --- PITFALLS.md | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/PITFALLS.md b/PITFALLS.md index 2cfcc46f..b4f6ed40 100644 --- a/PITFALLS.md +++ b/PITFALLS.md @@ -1,29 +1,31 @@ # Pitfalls -Dieser File dient zur Dokumentation von Problemen, welche während der Entwicklung auftreten. +This file is used to document problems, that occurred during development and how to fix them. ## Ionic Framework -### Template Files in gleichem Ordner wie Komponenten Files - -- ionic version 3.20.0 +### Build platform Android #### Problem -Ionic erwartet alle Dateien einer Komonentente im gleichen Verzeichnis. Sobald eine HTML Datei in einem Unterverzeichnis liegt, kommt es mit dem Tool `ionic serve` zu Caching Problemen. +After calling `ionic cordova build android` the gradle version is not set correctly (4.1 instead of 4.6) -## Andere +#### Solution -### TypeScript: automatische Imports fehlerhaft - -- typescript version <= 2.9.2 +* Go to folder `APP_FOLDER/platforms/android/cordova/lib/builders/` +* Open file `GradleBuilder.js` and change gradle version to `gradle-4.6-all.zip` +in line `var distributionUrl = process.env['CORDOVA_ANDROID_GRADLE_DISTRIBUTION_URL'] || +'https\\://services.gradle.org/distributions/gradle-4.1-all.zip';` +* Repeat this for file `StudioBuilder.js` +### Run platform iOS #### Problem -TypeScript suggeriert für empfohlene Imports den falschen Pfad. Für `ionic-angular` wird `ionic-angular/umd` importiert. Dies führt zur Ionic Fehlermeldung `cannot find module '.'` +Currently the iOS project build with cordova uses the old build system. +The command `ionic cordova run ios` runs into the error `/platforms/ios/build/emulator/StApps.app/Info.plist +file not found.` -Siehe auch Issue auf https://github.com/Microsoft/TypeScript/issues/25279 +#### Solution -#### Workaround - -- Installieren von dev build `Version 3.1.0-dev.20180728` mit `npm install -g typescript@next` +* Either use the command: `ionic cordova emulate ios -- --buildFlag="-UseModernBuildSystem=0"` +* Or open the iOS project in Xcode and change build system in workspace settings to `Lagacy Build System`. Then the normal run command works also.