Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support opening any Mastodon URL directly in the app #968

Open
sindresorhus opened this issue Mar 11, 2023 · 2 comments
Open

Support opening any Mastodon URL directly in the app #968

sindresorhus opened this issue Mar 11, 2023 · 2 comments

Comments

@sindresorhus
Copy link

sindresorhus commented Mar 11, 2023

Description

Support for custom URL schemes was added in #847, but they require the user to manually transform the URL.

Suggested Solution

It would be useful if you could simply open a link like https://mastodon.social/@sindresorhus/109983299847844086 with Mastodon and the app would show the post in the app.

This is especially useful when running the app on macOS as you could run something like:

open -a 'Mastodon' 'https://mastodon.social/@sindresorhus/109983299847844086'

My specific use-case is that I'm adding support for Mastodon in my browser picker app.

Other Mastodon clients like Ice Cubes and Mammoth already support this.

Alternatives

No response

Additional Context

If the app does not handle the given URL (for example, URL to settings or something), simply open it in a web view instead. This is what Ivory does.

Don't forget to declare support for URLs by adding this to Info.plist:

<key>CFBundleURLTypes</key>
<array>
	<dict>
		<key>CFBundleTypeRole</key>
		<string>Viewer</string>
		<key>CFBundleURLSchemes</key>
		<array>
			<string>https</string>
		</array>
	</dict>
</array>
@mvan231
Copy link

mvan231 commented May 24, 2023

Agreed! This would be great!

@cryofault
Copy link

I’d also love to see this if it’s the reason why me clicking “open using mastodon” just does nothing at all leaving me staring at safari. Other apps seem to work without issue so it left me confused and I had to copy/paste the link into mastodon search.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants