chart.js switch x/y axis on line chart
<p>Let's say I have a line chart like this: <a href="https://jsfiddle.net/13fyhL4j/" rel="noreferrer">https://jsfiddle.net/13fyhL4j/</a></p>

<p>HTML:</p>

<pre><code>&lt;script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.1.3/Chart.js"&gt;&lt;/script&gt;

&lt;canvas id="myChart" width="400" height="400"&gt;&lt;/canvas&gt;
</code></pre>

<p>JS:</p>

<pre><code>var ctx = document.getElementById("myChart");
var yLabels = [0, 2, 3, 6, 7];
var xLabels = ['A', 'B', 'C', 'D', 'E'];

var myChart = new Chart(ctx, {
    type: 'line',
    data: {
        labels: xLabels,
        datasets: [
            {
                type: 'line',
                label: 'Line',
                data: yLabels,
                fill: false,                
            }
        ]
    },
    options:{
        scales: {
                    xAxes: [{
                        display: true,
                        scaleLabel: {
                            display: true,
                            labelString: 'x label'
                        },

                    }],
                    yAxes: [{
                        display: true,
                        scaleLabel: {
                            display: true,
                            labelString: 'y label'
                        },

                    }]
                }
    }
});
</code></pre>

<p>Here x axis has category scale and y axis has linear scale. I need to swap axis, however, I cannot find how to make x axis linear and y axis category.</p>

<p><a href="https://i.stack.imgur.com/44JcD.png" rel="noreferrer">Image explaning situation</a></p>

<p>It is necessary to change not only the axis values, but also the chart itself.</p>