これがVSコードのデフォルトの動作であるかどうかわかりません(デフォルトの上にカスタム設定がたくさんあります)VSコード - 書式設定時にタグの終了とタグの開きを調整する方法は? (JSX)
しかし、コードをフォーマットすると、
const simpleInput = (
<Input
{...input}
{...others}
state={state}
/> <- Here is the difference
);
そして、私のES-lintはそれそれが並ぶので、私はそれを微調整することができますどのように[eslint] The closing bracket must be aligned with the line containing the opening tag (expected column 5) (react/jsx-closing-bracket-location)
に関する警告を投げる:中へ
const simpleInput = (
<Input
{...input}
{...others}
state={state}
/>
);
タグの開始と正しく?
ファイルが.jsファイル内でJSX
を使用しているよりも、VSコードaccordinglyを設定しました。
これは回避策、解決策ではありません。共有いただきありがとうございます。問題をよりよく理解することができます。 :) – Vadorequest