Can base files have aliases?

I’ve read and watched a few videos on bases, but have not seen anyone address this. I’m not very technical, so I may have missed it.

I’m using bases created as files as MOCs. I’d like to use a code block base to show my MOCs as cards (to function as easy buttons). But, the name has the file extension.

Can base files be given aliases? Or is there some formula that can remove the extension for a cleaner look?

A base file itself can’t have aliases, but a note containing an embedded or code block base can.

You can remove extension from non md files using this formula

file.asLink(file.name.split(".",1))

Other string styles in bases:

file.asLink(file.name.trim().split(".",1).toString().replace(" ","-").title())

 

Place these formulas under Properties –> Add formula

 

In theory you could use .replace(⋯) to manipulate file names with certain patterns although in Obsidian we cannot assign custom properties to arbitrary files (only to md or note files). However the thing is that these arbitrary files have implicit properties which could be used in formulas:


https://help.obsidian.md/bases/syntax#File%20properties

 

There are plugins like Binary File Manager that automatically convert arbitrary files to note files (or md files) which can then feature custom properties. The problem is that sometimes implicit properties are enough so Binary File Manager’s automatic conversion is not always needed. Hence you could somehow toggle the plugin into use when you want to make such conversions.