These are chat archives for angular/angular-2-ionic-2

28th
Feb 2018
ahmadlinus
@ahmadlinus
Feb 28 2018 15:29
Hi, I have yet another problem in my ionic 3 project: the inappbrowser I am using to login in the start is causing trouble in the app. I close it with browser.close() but it remains somehow in the memory and slows down the app. I experience a slow-down when I try to switch between tabs or segments in the app. When I close the app and open it once again, (no login, and thus, no inappbrowser) I see the UI works fine again. Does anybody have an idea?
Doug Franklin
@Imaginativeone
Feb 28 2018 16:11
@ahmadlinus Is there a way to close the entire chain of components?
Hi, my attribute directive works on my pages directly. However, it does not work when routed through tabs. What am I doing wrong?
Owen Melbourne
@OwenMelbz
Feb 28 2018 20:04
anybody know to get typescript to ignore a file/bunch of errors? i'm having to import a random library, which isnt in typescript, so i've put it in a class which im injecting - however when i compile it kicks up a fuss like
Typescript Error
Expected 0 arguments, but got 13.
UncertaintyP
@UncertaintyP
Feb 28 2018 20:18
When importing other libs ( I use glfx for example ) you download the minified version, add it to your index.html and put a declare var fx: any; on top of your page/provider... (in this case fx is the object exported by glfx)
Owen Melbourne
@OwenMelbz
Feb 28 2018 20:19
where do you store the js file? its only needed in like 1 component
UncertaintyP
@UncertaintyP
Feb 28 2018 20:19
assets/js
yeah my lib too :D you can of course create a more fine grained folder structure of your external js libs
Owen Melbourne
@OwenMelbz
Feb 28 2018 20:24
just wondering if i can do import * as keyshape from '../../assets/js/keyshape';
hmm
Error: Module parse failed: Unexpected token (1:24)
You may need an appropriate loader to handle this file type.
| export default keyshape function() {
Owen Melbourne
@OwenMelbz
Feb 28 2018 20:38
@UncertaintyP you able to explain that declare thing a little more? i've got window.keyshape working
but the page is saying it cant find keyshape on window
oh there we go, working now
UncertaintyP
@UncertaintyP
Feb 28 2018 23:54
@OwenMelbz It tells typescript that there is a variable name that's of the type T where T is one of the possible declaration types