# Plotly.js subplot issue, only shows the last one data

**URL:** <https://community.plotly.com/t/plotly-js-subplot-issue-only-shows-the-last-one-data/21795>\
**Category:** plotly.js\
**Created:** [April 2, 2019, 7:41pm UTC](https://community.plotly.com/t/plotly-js-subplot-issue-only-shows-the-last-one-data/21795 "2019-04-02T19:41:21Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![wangz35](https://avatars.discourse-cdn.com/v4/letter/w/13edae/32.png) [@wangz35](https://community.plotly.com/u/wangz35)\
**Post date:** [April 2, 2019, 7:41pm UTC](https://community.plotly.com/t/plotly-js-subplot-issue-only-shows-the-last-one-data/21795/1 "2019-04-02T19:41:21Z")

</div>

I have a javascript project, and using plotly.js for graph analysis. My goal is to show two plots in one website page, each plot contains two sets of data, two lines. I learned to use subplot function, and layout setting. I tested that in my demo website, works fine. But when I complied the layout, data to my project, the plot only shows the last set data, so one line. The funny thing is the names of Axis are overlaying. I attached the images.

 ![14%20PM](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/7/7d81c13228bb2b0a25f6bd742474ab079dca6679.png) ![25%20PM](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/9/9f077f407eca799bffe950b1940201e16bc04c86.png)

---

<div class="post-metadata">

**Author:** ![etienne](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/etienne/32/17_2.png) [@etienne](https://community.plotly.com/u/etienne)\
**Post date:** [April 3, 2019, 9:01pm UTC](https://community.plotly.com/t/plotly-js-subplot-issue-only-shows-the-last-one-data/21795/2 "2019-04-03T21:01:23Z")

</div>

Could you share a reproducible code snippet to help us help you?
