facebook

CodeMix format onSave outcome is different than my repository settings

  1. CodeMix & Angular IDE
  2.  > 
  3. Getting Help
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #617055 Reply

    codejedi365
    Participant

    I am working with a project build from a scaffold by Vue CLI 3 which integrates prettier as the ESLint extension. It builds a npm script for linting ‘npm run lint –fix’ (converts to vue-cli-service lint –fix) and when I run this from an external command line I get the formatted code settings I desire. When I turn on CodeMix’s format on Save, It formats to different settings that I don’t like. I have tried going through the options to make them match and its close but not complete. How can I force CodeMix to just run that npm command instead per the saved file? Im wondering about the eslint.runtime parameter? Or do I need to tell it to look at specific prettier configuration file?

    #617104 Reply

    Brian Fernandes
    Moderator

    codejedi,

    1) Bottom line is that the prettier configuration file would be the way to go, CodeMix will not be able to run an external command to format the files.
    2) Have you checked the settings under Preferences > Formatter > Vue and Preferences > Extensions > Vue > Format Default Formatter – are these the options you are talking about, and have already tweaked?
    3) Any difference in behavior if you format the file manually (i.e. not on save)?
    4) When creating the project you could choose to use dedicated configuration files (you could do this for a new project and copy the files over) this should create files in the project that the IDE formatter should respect.

    If not too much trouble, would it be possible to send us a sample project that exhibits this problem? Will help ensure we’re on the same page and can work on a fix, if required, ASAP.

    Thanks!

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: CodeMix format onSave outcome is different than my repository settings

You must be logged in to post in the forum log in