Add page alias without creating a file

In logseq creating a page using [[New Page]] doesn’t create the file is file-system unless some data is added in the page. - which is something I like.

So, is it possible to add an alias to a page without actually create the file?

For example I have pages for contacts or people which i’m nesting under a parent page called [[@]] (as suggested here). But some people have different names for their online presence than thei actual name. So I don’t want to create a new file for both their online name and actual name.

For Example:

Can you clarify the problem? To me, it would seem logical that that you have at least one exiting page, e.g. [[@/Daniel Shiffman]], but not [[@/The Coding Train]]. It would be sufficient to add the property alias:: The Coding Train to the exiting page to reference the person by the two names. I probably am missing something in your question, so could you explain the specific issue somewhat more?

In brief, I do not think it is possible to create an alias to a page that does not yet exist. You can use those different names, but they will only point to the same page the moment that

  1. You create one physical file, and
  2. in it, define an alias.

From that point onwards, both references will “magically” refer to the same page.

@vanadium What you described is accurate and what I’m looking for.
I was wondering if its possible to add alias without having a physical file - probably something in the settings or config.edn etc…

Others can correct me if I’m wrong, but in my experience Logseq will create a file for a page “lazily”. That is, it will only create a new file for a page once content starts showing up on it.

I just tried this also for an alias. I have a hierarchy of pages that start with “P/” to designate them as projects. I also had a “Projects” page in which I list them out differently. I make “P” an alias for the “Projects” page. Everything still works at I expected but no P.md was ever created.

You should experiment on your own to verify.

In your scenario, you will have a Projects.md file created in your directory.
What I want I to not create any files - I just want to use the name for references without having any actual content and also have the ability to add alias to the name.

That is not possible. The alias names are stored in the page files.

Like I said before, you can reference a page all day long and the file won’t be created until you go to that page and start typing something. So you can tag things that don’t have an associated file. But if you want an alias to that same tag as well, you have to go to that page and specify what that alias is going to be. Once you start typing, though, the file will get automatically created and it will store the alias information.