Closed mariusa closed 4 years ago
Why? It's good for debugging purpose. That's why it's only used when NODE_ENV !== 'production'
. And we've also provided a prettify
option to turn it off.
To avoid yet another dependency. It seems strange for a compiler to do code formatting. There are separate tools to do debugging, code editing, etc. A compiler should focus on compiling.
For now, we still need code formatting at this level for a better template debugging experience.
We can remove it for Vue 3, though, because templates in Vue 3 will have much better source map support.
A compiler shouldn't depend on code formatting / beautifier utilities. That's the job of the IDE. vscode already handles this very well, for example.
Would you please remove prettier dependency?