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

23rd
Sep 2016
Valentyn Shybanov
@olostan
Sep 23 2016 00:54
seems ionic 2 that uses angular 2 is not able to use anything from ionic-native :(
(I mean angular 2 release, not rc4)
spend several hours converting my app to release and got driftyco/ionic-native#569 - this is stopper issue :(
Valentyn Shybanov
@olostan
Sep 23 2016 01:02
This message was deleted
Valentyn Shybanov
@olostan
Sep 23 2016 01:10
My bad. npm i --save ionic-native@latest helped.
Valentyn Shybanov
@olostan
Sep 23 2016 02:29
Anyone tried to use 'ion-button in last beta? Angular say 'ion-button' is not a known element... But I am importing IonicModule.forRoot(MyApp),....
Valentyn Shybanov
@olostan
Sep 23 2016 02:50
if anyone interested - you should use as <button ion-button>..
G
@gravity-addiction
Sep 23 2016 02:56
good to know..
ōŋѕεĿ αкıи
@onselakin
Sep 23 2016 11:02
Hey guys! I have a button and I want to let the parent component to know the background color of the button when it is clicked: <button block (click)=“onColorSelected.emit(what_should_I_put_here)"></button>
What’s the best way to do this?
Should I give up emitter and use another approach?
Valentyn Shybanov
@olostan
Sep 23 2016 11:31
@onselakin try: <button #colorSelector (click)="onColorSelected.emit(colorSelector.styles.backgroundColor"> or something like that. Idea - reference button element with #
ōŋѕεĿ αкıи
@onselakin
Sep 23 2016 12:35
@olostan Thanks. styles doesn’t work so I used _elementRef.nativeElement.style.backgroundColor
Valentyn Shybanov
@olostan
Sep 23 2016 14:32
@onselakin I didn't saw your template, so wrote pseudo-code. Basically # allows to to get reference to some DOM element (native, angular or even web component), see https://angular.io/docs/ts/latest/guide/template-syntax.html#!#ref-vars
ōŋѕεĿ αкıи
@onselakin
Sep 23 2016 14:37
@olostan Yes I used an element reference, just a different path to access the style.
Valentyn Shybanov
@olostan
Sep 23 2016 14:38
@onselakin glad it helped :)
ōŋѕεĿ αкıи
@onselakin
Sep 23 2016 15:03
@olostan :+1:
blop.. blop..
@bluethefish
Sep 23 2016 15:50
there is component for speed dial?
Christophe Durieux
@codedumper
Sep 23 2016 16:00
is there a version of ionic2 working with angular 2.0 final ?
Valentyn Shybanov
@olostan
Sep 23 2016 16:00
yes.
2.1.0-beta2 seems works ok with release
Christophe Durieux
@codedumper
Sep 23 2016 16:01
ok, need to upgrade angular after ionic start ?
Valentyn Shybanov
@olostan
Sep 23 2016 16:02
ionic start will generate project based on rc4
Christophe Durieux
@codedumper
Sep 23 2016 16:02
thereis a big step between rc4 and final
i just spent a lot of time migrating my browser app from rc5 to final.
Valentyn Shybanov
@olostan
Sep 23 2016 16:04
there is a base+blank/tab projects in github that you can use to start new app based on angular 2
Christophe Durieux
@codedumper
Sep 23 2016 16:06
@olostan Thanks, i will definitively try it.
Valentyn Shybanov
@olostan
Sep 23 2016 16:06
just switch to "beta-11" branches
Christophe Durieux
@codedumper
Sep 23 2016 16:07
i saw the previous messages, beta-11 and ionic-angular nightly build ? right ?
Christophe Durieux
@codedumper
Sep 23 2016 16:27
@olostan npm install git://github.com/driftyco/ionic.git#v2.0.0-beta.11 -g install beta.10 ?
Alex
@zefrench
Sep 23 2016 20:09
Hi everybody I need some help for an HTTP.get request. I'm unable to receive the information from the php server.
Is someone can help me with this.
Kyle Roach
@iRoachie
Sep 23 2016 20:25
What's the actual problem ?
Alex
@zefrench
Sep 23 2016 20:26

I send this to My php server :
var headers = new Headers();
headers.append('Content-Type', 'application/x-www-form-urlencoded; charset=UTF-8');

this.http.get('http://localhost/stripe/save.php?token='+response.id+'&email=email=xxxxxx@xxxxxx.net', {headers: headers})
.map(res => res.json()).subscribe(data => {
console.log(data);
});

The php receive the informations (token and email address) and create my customer in stripe.
Then stripe return a lot of information and all is working well but I'm not able to receive the information on my angular file.
console.log(data) does not receive anything from my php file.
I send the data from php with the echo $data command.
Alex
@zefrench
Sep 23 2016 20:55
@iRoachie do you have some idea ?
Myck
@mickadoua
Sep 23 2016 23:40

hello all,
some problem with ionic2 today

i dont know why but
<button block>Block Button</button>
was not converted to <button block="" class="button button-default button-block">Block Button</button>
but stay like this <button block="" class="">Block Button</button>

Myck
@mickadoua
Sep 23 2016 23:51
answer to myself
the content of node_module> ionic-angular> components > button > button.js whas not the same as, a new project
i dont know why, heaven after delete node_module's folder, and npm install, i have this issue