# Fullscreen Elm App in 0.19 (childNode issue) Reopened again

**URL:** <https://discourse.elm-lang.org/t/fullscreen-elm-app-in-0-19-childnode-issue-reopened-again/4160>\
**Category:** Request Feedback\
**Created:** [August 14, 2019, 6:02am UTC](https://discourse.elm-lang.org/t/fullscreen-elm-app-in-0-19-childnode-issue-reopened-again/4160 "2019-08-14T06:02:59Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![simonh1000](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.elm-lang.org/simonh1000/32/100_2.png) [@simonh1000](https://discourse.elm-lang.org/u/simonh1000)\
**Post date:** [August 14, 2019, 6:02am UTC](https://discourse.elm-lang.org/t/fullscreen-elm-app-in-0-19-childnode-issue-reopened-again/4160/1 "2019-08-14T06:02:59Z")

</div>

This builds on

- [Fullscreen Elm App in 0.19 (childNode issue) Reopened](https://discourse.elm-lang.org/t/fullscreen-elm-app-in-0-19-childnode-issue-reopened/3174/19)
- [Web-components interop (childNode issues)](https://discourse.elm-lang.org/t/web-components-interop-childnode-issues/3730)

I noticed the same issue with the google maps webcomponent from polymer. The question raised by @evancz before was where in the dom tree are changes being made, and in this case the answer is ‘pretty random’ - you can see that in addition to adding children to the `google-map` element, a script tag has been inserted between two of the other children.

The lies in the way that `IronJsonpLibraryBehavior` is implemented, but I suspect is widely used in Polymer. The key code reads

```auto
  addScript: function(src) {
    var script = document.createElement('script');
    script.src = src;
    script.onerror = this.handleError.bind(this);
    var s = document.querySelector('script') || document.body;
    s.parentNode.insertBefore(script, s);
    this.script = script;
  },

```

So the work around seems to be place a `<script>` tag somewhere in the html. Orherwise I suppose it is some sort of race condition that leads to placement of the script tag between two of the elm divs.

 ![image](https://canada1.discourse-cdn.com/flex035/uploads/elm_lang/original/2X/1/19311ef9547e74077fc0fc1aaec0dd129bf99025.png)

> **[simonh1000/elm-gmap-webcomp-bug](https://github.com/simonh1000/elm-gmap-webcomp-bug)**
>
> Contribute to simonh1000/elm-gmap-webcomp-bug development by creating an account on GitHub.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex035/uploads/elm_lang/original/1X/50a05e53677a2c3b47776d7abd0f113eb50193a1.png) [@system](https://discourse.elm-lang.org/u/system)\
**Post date:** [August 24, 2019, 6:03am UTC](https://discourse.elm-lang.org/t/fullscreen-elm-app-in-0-19-childnode-issue-reopened-again/4160/2 "2019-08-24T06:03:00Z")

</div>

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.
