slash icon indicating copy to clipboard operation
slash copied to clipboard

Option to not have the /s/ in the url

Open liamlah opened this issue 1 year ago • 16 comments

Is your feature request related to a problem?

This is a great idea, thank you for creating this.

If I am dedicating a domain/subdomain to this service, ideally I'd want the url to be as short as functionally possible. The /s/ seems like 2 potentially unnecessary characters.

Describe the solution you'd like

If technically feasible an option to not have the /s/ in the url.

Additional context

I do independent technical support, and this could help me when directing someone to a url over the phone, in a situation where a url is being communicated verbally, the fewer characters, the better

liamlah avatar Jul 22 '23 15:07 liamlah

This would be cool, even if it was an option panel to choose what you'd like in place of the /s/.

  • /s/
  • /
  • /[custom]/

fidst avatar Jul 22 '23 15:07 fidst

This is the only thing stopping me from switching from yourls to this.. i don't need a /s/ i just want domain/custom

danmed avatar Jul 22 '23 19:07 danmed

If you use a reverse proxy like caddy

s.domain.com {
@subdir {
 not path /s/*
 not file
 }
 rewrite @subdir /s{uri}
 reverse_proxy 172.17.0.1:8880
}

This will redirect s.domain.com/link to s.domain.com/s/link and redirects to destination

PaddyPat avatar Sep 15 '23 04:09 PaddyPat

If you use a reverse proxy like caddy

s.domain.com {
@subdir {
 not path /s/*
 not file
 }
 rewrite @subdir /s{uri}
 reverse_proxy 172.17.0.1:8880
}

This will redirect s.domain.com/link to s.domain.com/s/link and redirects to destination

would the same work nginx proxymanager?

mobiledude avatar Sep 17 '23 07:09 mobiledude

If you use a reverse proxy like caddy

s.domain.com {
@subdir {
 not path /s/*
 not file
 }
 rewrite @subdir /s{uri}
 reverse_proxy 172.17.0.1:8880
}

This will redirect s.domain.com/link to s.domain.com/s/link and redirects to destination

would the same work nginx proxymanager?

Think so but I don’t use nginx.. it’s too complicated

PaddyPat avatar Sep 19 '23 19:09 PaddyPat

Is there any plans to implement this?

RealFascinated avatar Jan 15 '24 19:01 RealFascinated

It's probably impossible to remove the s/ prefix from slash itself. However, it is recommended that you use a reverse proxy such as nginx to do so.

boojack avatar Jan 21 '24 09:01 boojack

Would you be open to a pull request making this happen? It seems pretty easy to do.

rdamazio avatar Mar 23 '24 11:03 rdamazio

(And btw, in Chrome my workaround so far is to add a search engine defined as the Slash url, and basically use space instead of / - but not ideal if you're deploying to many users)

rdamazio avatar Mar 23 '24 11:03 rdamazio

@rdamazio FYI, Slash have another model Collection for sharing selected shortcuts, like a folder. And it would be prefixed with c/. So I think the necessary prefixes are needed.

image

boojack avatar Mar 25 '24 02:03 boojack

@rdamazio FYI, Slash have another model Collection for sharing selected shortcuts, like a folder. And it would be prefixed with c/. So I think the necessary prefixes are needed.

You can just make one or both prefixes configurable - e.g. still use /c for collections but configure no prefix for shortcuts. Obviously that prevents having a shortcut called "c" (as well as one named the same as the prefix for the admin pages and API endpoints), but that's minor.

rdamazio avatar Mar 25 '24 02:03 rdamazio

Surprised this isn't a thing yet.

adiologydev avatar Apr 08 '24 20:04 adiologydev

It would be good to have configurable prefix's or none at all. We are looking for a shorting service to run internally and this would fit the bill without the prefix

craftzneko avatar Jun 08 '24 09:06 craftzneko

I took a first stab at this and got the server side working and part of the frontend, but my limited knowledge of React is making it very slow to make the frontend changes (I'm a backend person). Would anyone like to take over what I have so far?

rdamazio avatar Jun 10 '24 00:06 rdamazio

I took a first stab at this and got the server side working and part of the frontend, but my limited knowledge of React is making it very slow to make the frontend changes (I'm a backend person). Would anyone like to take over what I have so far?

Sure, I'd be happy to finish this up.

adiologydev avatar Jun 10 '24 07:06 adiologydev

I took a first stab at this and got the server side working and part of the frontend, but my limited knowledge of React is making it very slow to make the frontend changes (I'm a backend person). Would anyone like to take over what I have so far?

Sure, I'd be happy to finish this up.

Pushed to https://github.com/rdamazio/slash.

rdamazio avatar Jun 10 '24 09:06 rdamazio