0

web mode indent not correct when line too long. the code:

<script>
  import axios from 'axios'

  export default {
    components: {

    },
    asyncData ({ params }) {

      return axios
        .get().then((res) => {
          return { title: res.data.title }
      })
    }
  }
</script>

The following is correct.

      return axios
        .get().then((res) => {
          return { title: res.data.title }
      })

but:

      return axios.get()
             .then((res) => {
          return { title: res.data.title }
      })

when i break line behind "axios", it's not correct

anybody help??

1 Answer 1

2

Ah... I found it.

(add-to-list 'web-mode-indentation-params '("lineup-calls" . nil))
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.