# Removing line numbers from ref labels

**URL:** https://community.silverbullet.md/t/removing-line-numbers-from-ref-labels/3671
**Category:** General
**Created:** [December 25, 2025, 8:56pm UTC](https://community.silverbullet.md/t/removing-line-numbers-from-ref-labels/3671 "2025-12-25T20:56:24Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Platinum](https://community.silverbullet.md/user_avatar/community.silverbullet.md/platinum/32/2510_2.png) [@Platinum](https://community.silverbullet.md/u/Platinum)
#### Post date: [December 25, 2025, 8:56pm UTC](https://community.silverbullet.md/t/removing-line-numbers-from-ref-labels/3671/1 "2025-12-25T20:56:24Z")

</div>

For reference throughout, including in queries, Linked Mentions, Linked Tasks and such, would it be possible to remove the `@<lineno>` part from the label (but not the actual link)?

For instance, the [first two links here](https://silverbullet.md/Space%20Style) are `Manual@2485` and `Manual@2485`. I’d like each to simply read `Manual`, but retain the links to the line numbers.

I see that these come from the built in templates, and I tried to override one of them using `space-lua`:

```space-lua
-- Renders a task object as a togglable task
templates.taskItem = template.new([==[
* [${state}] [[${ref}|Task]] ${name}
]==])

```

This did not work. I’m able to create my own templates like the above and use them, but how do I override built-ins?

---

<div class="post-metadata">

### Author: ![bau](https://community.silverbullet.md/user_avatar/community.silverbullet.md/bau/32/2597_2.png) [@bau](https://community.silverbullet.md/u/bau)
#### Post date: [December 26, 2025, 7:34am UTC](https://community.silverbullet.md/t/removing-line-numbers-from-ref-labels/3671/2 "2025-12-26T07:34:54Z")

</div>

Force the execution of your space-lua at the end of the stack by assigning a negative value to the `priority` property (note: [specific syntax](https://silverbullet.md/Space%20Lua%25401350)):

```auto
-- priority: -1

-- Renders a task object as a togglable task
templates.taskItem = template.new([==[
* [${state}] [[${ref}|Task]] ${name}
]==])

```

---

<div class="post-metadata">

### Author: ![Platinum](https://community.silverbullet.md/user_avatar/community.silverbullet.md/platinum/32/2510_2.png) [@Platinum](https://community.silverbullet.md/u/Platinum)
#### Post date: [December 26, 2025, 8:35am UTC](https://community.silverbullet.md/t/removing-line-numbers-from-ref-labels/3671/3 "2025-12-26T08:35:43Z")

</div>

This is strange. I asked [deepwiki](https://deepwiki.com/search/for-reference-throughout-inclu_fd13aeb3-29b9-4305-a8dc-7fbf47626572?mode=fast), it said the same thing, and its solution worked. But why did mine not work? It’s not clear to me: if I add an `x` anywhere in my template, it works. If I remove it, it doesn’t. Not sure why. I at least do have it working for now.

---

<div class="post-metadata">

### Author: ![Platinum](https://community.silverbullet.md/user_avatar/community.silverbullet.md/platinum/32/2510_2.png) [@Platinum](https://community.silverbullet.md/u/Platinum)
#### Post date: [December 26, 2025, 8:38am UTC](https://community.silverbullet.md/t/removing-line-numbers-from-ref-labels/3671/4 "2025-12-26T08:38:25Z")

</div>

Thank you for the suggestion. I did this and it worked, but now, it’s working without that either. I’m not sure what’s going on, but I do have it working. Thanks again!

---

<div class="post-metadata">

### Author: ![bau](https://community.silverbullet.md/user_avatar/community.silverbullet.md/bau/32/2597_2.png) [@bau](https://community.silverbullet.md/u/bau)
#### Post date: [December 26, 2025, 10:01am UTC](https://community.silverbullet.md/t/removing-line-numbers-from-ref-labels/3671/5 "2025-12-26T10:01:15Z")

</div>

It’s weird … ! For me:

- setting the priority to 0 (as recommended by deepwiki) does not work
- setting it to -1 works in all cases

---

<div class="post-metadata">

### Author: ![bau](https://community.silverbullet.md/user_avatar/community.silverbullet.md/bau/32/2597_2.png) [@bau](https://community.silverbullet.md/u/bau)
#### Post date: [December 26, 2025, 10:46am UTC](https://community.silverbullet.md/t/removing-line-numbers-from-ref-labels/3671/6 "2025-12-26T10:46:05Z")

</div>

It is also necessary to distinguish:

- create a task (in a list, on a page - Example : list Todo)
- view it (on this same page or any other) via a template

The task status can be changed in two places:

- in the original list (eg: list Todo): the new status is NOT automatically propagated in the visualization (the space-lua expression must be reload)
- in the visualization: the new status is immediately propagated in the original list PROVIDED that the `ref` is still valid (as you point out in your other post: [Observations on Live Editing](https://community.silverbullet.md/t/observations-on-live-editing/3672))
