<div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="// 1. input `w,`
w
window,
// 2. input `window`, move caret to line head by using arrow key, input `!`
window
window!window"><pre class="notranslate"><span class="pl-c">// 1. input `w,`</span>
<span class="pl-s1">w</span>
<span class="pl-smi">window</span><span class="pl-kos">,</span>
<span class="pl-c">// 2. input `window`, move caret to line head by using arrow key, input `!`</span>
<span class="pl-smi">window</span>
<span class="pl-smi">window</span><span class="pl-c1">!</span><span class="pl-kos"></span><span class="pl-smi">window</span></pre></div>
<div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="interface I {
    property1: number;
    property2: string;
}

var x: I = {
    /**/property1
}"><pre class="notranslate"><span class="pl-k">interface</span> <span class="pl-smi">I</span> <span class="pl-kos">{</span>
    <span class="pl-c1">property1</span>: <span class="pl-smi">number</span><span class="pl-kos">;</span>
    <span class="pl-c1">property2</span>: <span class="pl-smi">string</span><span class="pl-kos">;</span>
<span class="pl-kos">}</span>

<span class="pl-k">var</span> <span class="pl-s1">x</span>: <span class="pl-smi">I</span> <span class="pl-c1">=</span> <span class="pl-kos">{</span>
    <span class="pl-c">/**/</span>property1
<span class="pl-kos">}</span></pre></div>
<p dir="auto">Both <code class="notranslate">property1</code> and <code class="notranslate">property2</code> are suggested at that position even though it currently exists in the object literal. To make this worse, if you commit with `property1, you end up with the following:</p>
<div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="interface I {
    property1: number;
    property2: string;
}

var x: I = {
    property1property1
}"><pre class="notranslate"><span class="pl-k">interface</span> <span class="pl-smi">I</span> <span class="pl-kos">{</span>
    <span class="pl-c1">property1</span>: <span class="pl-smi">number</span><span class="pl-kos">;</span>
    <span class="pl-c1">property2</span>: <span class="pl-smi">string</span><span class="pl-kos">;</span>
<span class="pl-kos">}</span>

<span class="pl-k">var</span> <span class="pl-s1">x</span>: <span class="pl-smi">I</span> <span class="pl-c1">=</span> <span class="pl-kos">{</span>
    property1property1
<span class="pl-kos">}</span></pre></div>