0

This problem only happens on Firefox, works fine on Chrome and Safari. I have no clue why this is happening and I've been googling and stack overflowing, but none of them facing the same problem as I do.

The whole web app doesn't interact at all on firefox. Button clicked but nothing happened. (If it's a route link, it will navigate.) Here is a simple version of the problem.

For example, I got a button that regenerates some data. This data then gets past to the child component(graph component) for plotting. I have put down console log at three places.

  1. click event callback.
  2. data generation method.
  3. ngOnChange() of the child component.

I've opened up both chrome and firefox browser. Chrome prints all three logs, but Firefox only print the first two. So my initial conclusion is the click event was triggered, data has been generated, but ngOnChange event somehow not triggered in Firefox.

Has anyone got the same issue before or is it got nothing to do with the ngOnChange lifecycle?

UPDATE: The ngOnChange does get triggered at the beginning

MaXon
  • 465
  • 2
  • 8
  • 17
  • Could you provide some code so we can see it? It would be much easier to test and troubleshoot to help you. – Ryan Jul 26 '18 at 04:51
  • @rncrtr thanks for the reply, I was testing out something before. The code itself won't explains much unless I provide you with the whole project. (The reason I'm saying this is, I've tested this in a brand new project, and everything works fine on both Chrome and Firefox.) What I just found or testing with is, I tried to use service to pass the data, and the data did get through, but the DOM is not rendering. For example, I passed a boolean to the component, and it should render something if the boolean is true. However, nothing gets rendered. – MaXon Jul 26 '18 at 06:24
  • Even knowing what version of angular you're running could help -- because they vary a lot based on the release -- or a small example in a demo like at jsfiddle.net, plunkr.co or codepen.io (all three are free) would allow me to try it out and figure out why you get this issue. Most of the time questions like this (without something to look at and test) get closed without anyone helping and I don't want that to happen to you if possible. – Ryan Jul 26 '18 at 16:17

0 Answers0