atom-elixir-formatter
atom-elixir-formatter copied to clipboard
Formatter does not save heex files
I upgraded to the latest and greatest, but the Formatter does not allow saving of .heex files, getting this errror:
mix format failed for file: lib/farmemerg_web/live/response_live/index.html.heex ** (SyntaxError) lib/farmemerg_web/live/response_live/index.html.heex:1:1: syntax error before: '<' (elixir 1.12.2) lib/code.ex:978: Code.format_string!/2 (mix 1.12.2) lib/mix/tasks/format.ex:418: Mix.Tasks.Format.format_file/2 (elixir 1.12.2) lib/task/supervised.ex:90: Task.Supervised.invoke_mfa/2 (elixir 1.12.2) lib/task/supervised.ex:35: Task.Supervised.reply/5 (stdlib 3.15.2) proc_lib.erl:226: :proc_lib.init_p_do_apply/3
The first line is:
File heading
it does save if you remove the formatter.
Thanks for the bug report @arnimikelsons. Are you seeing this issue on all heex
files or just one in particular?
@rgreenjr I am seeing it on every file. I had turned formatting off for now, but it is also on .eex files as well.
@arnimikelsons I reverted support for heex
files and published v2.2.0. However, the Atom packages API server continues to have issues, so I'm not sure if this updated version will be visible. Please let me know if you are able to see the new release.
I see it it in the list, but when I try to install I get:
Installing “[email protected]” failed. Package version: 2.2.0 not found
Good news: it looks like v2.2.0 is now available. I uninstalled my current version of the pacakge, restarted Atom, and was able to install 2.2.0 successfully. Hopefully, you will be able to get the same result.
I wonder why this happens, I can't reproduce it on my projects.
So, editing heex or eex files, they are saving, but the error still pops up. I actually don't know if what I reported before was saving and just popping up the error, or if it actually wasn't saving.