monaco-editor version: Actual Playground
Browser: Chrome 76.0.3809.100
OS: Windows 10
Go to https://microsoft.github.io/monaco-editor/playground.html#interacting-with-the-editor-rendering-glyphs-in-the-margin
Set cursor to the start of the line number 3.
Press Enter.

That's what the stickiness property is for AFAICT. You can try it with the following options object
options: {
isWholeLine: true,
className: 'myContentClass',
glyphMarginClassName: 'myGlyphMarginClass',
stickiness: monaco.editor.TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges,
}
I consider that is most powerful option and it should be adding into the playground example.
PR welcome.
Most helpful comment
That's what the
stickinessproperty is for AFAICT. You can try it with the followingoptionsobject