# Inline node with optional content

**URL:** https://discuss.prosemirror.net/t/inline-node-with-optional-content/6273
**Category:** Uncategorized
**Created:** [March 13, 2024, 1:15pm UTC](https://discuss.prosemirror.net/t/inline-node-with-optional-content/6273 "2024-03-13T13:15:29Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![trailskr](https://discuss.prosemirror.net/user_avatar/discuss.prosemirror.net/trailskr/32/3955_2.png) [@trailskr](https://discuss.prosemirror.net/u/trailskr)
#### Post date: [March 13, 2024, 1:15pm UTC](https://discuss.prosemirror.net/t/inline-node-with-optional-content/6273/1 "2024-03-13T13:15:29Z")

</div>

I need to create a link with optional text content, the basic information is combined from the attributes into the content of the pseudo element ::before. I can’t use marks because they can’t be empty.

![image](https://discuss.prosemirror.net/uploads/secondsite/original/2X/a/a5c22b2255c0b16cea8384560e7f07dd1d2a1589.png)

Therefore I want to use inline node with content, but it behaviour is awful:

![chrome-capture-2024-3-13](https://discuss.prosemirror.net/uploads/secondsite/original/2X/6/6e691a304684dd005fffe8417c864af88d792f77.gif)

I can’t select the node itself, put cursor inside of it or even put cursor after its contents. Such problems have been discussed here [inline-nodes-with-content](https://discuss.prosemirror.net/t/discussion-inline-nodes-with-content/496/3). But when inline node is described without content - I can select node and put cursor after it content. I want to be able to select whole node, put cursor inside and after the element. Can I do this without custom node views?
