Why the heck does the new Shopify code editor keep doing this to my files?
It is really frustrating now and making them a mess - and it just seems to randomly do it without even any interaction.
Does anyone know if there is a setting that is causing this or how I can fix/revert the formatting within this editor so I don’t have to waste time copying the code to another editor to sort it out and paste it back into here?
Hi @zigojacko
I’m not seeing this on my side - if you test with a fresh version of Horizon are you experiencing the same issue?
Hey @Liam-Shopify - I don’t have any clients using Horizon at the moment and it is difficult to test as it has only happened about 5 times since this new code editor was released and seemingly completely randomly so I do not know how to trigger it. I would have to be working in the codebase for a website for many days/weeks to see if this happens.
I am wondering if it is only in .liquid files though. I have a feeling it was also a script in a liquid template last time this happened like my example above.
Not sure if there is even a setting/config that would format a file like that to trigger neither…. Never experienced this in vscode.
This happened to me just now again.
Opened the global.js file and within 5 minutes of being open in the code editor and absolutely zero interaction with not just the file but the entire tab in the browser, the entire file got converted to this mess (over 1000 lines of JS indented concurrently every line).
This must be some sort of bug surely…?
Hi again @zigojacko
Is this happening only with .js files?
Hey @Liam-Shopify from what I can remember, it is happening with JS code, not necessarily in a .js file, it could just be a in a liquid file and this has happened (as well as JS files).
I can’t remember an instance where it has happened with liquid code so yeah, I think just JS.