Support us by giving us a
star on Github 🚀

Device component best practices

`dont-use-device-condition`: Don't use device condition to show or hide the component
It is strongly advised to utilize the [`ftd.desktop`](/desktop/) and [`ftd.mobile`](/mobile/) components in order to display components on desktop and mobile devices, respectively. This is because `fastn` performs optimization techniques, including decreasing the size of the created component tree, generating optimized code that renders quickly, and reducing the component's dependencies. Additionally, it handles the variant of properties, such as `ftd.responsive-type` and `ftd.length.responsive`, that are specified for the corresponding devices.
Not recommended
-- desktop-page:
if: { ftd.device == "desktop" }
Lang:
ftd
Recommended
-- ftd.desktop:

-- desktop-page:

-- end: ftd.desktop
Lang:
ftd

Support `fastn`!

Enjoying `fastn`? Please consider giving us a star ⭐️ on [GitHub](https://github.com/fastn-stack/fastn) to show your support!
[⭐️](https://github.com/fastn-stack/fastn)

Getting Help

Have a question or need help? Visit our [GitHub Q&A discussion](https://github.com/fastn-stack/fastn/discussions/categories/q-a) to get answers and subscribe to it to stay tuned. Join our [Discord](https://discord.gg/a7eBUeutWD) channel and share your thoughts, suggestion, question etc. Connect with our [community](/community/)!
[💻️](/community/)

Found an issue?

If you find some issue, please visit our [GitHub issues](https://github.com/fastn-stack/fastn/issues) to tell us about it.

Quick links:

- [Install `fastn`](install/) - [Create `fastn` package](create-fastn-package/) - [Expander Crash Course](expander/) - [Syntax Highlighting in Sublime Text](/sublime/)

Join us

We welcome you to join our [Discord](https://discord.gg/a7eBUeutWD) community today. We are trying to create the language for human beings and we do not believe it would be possible without your support. We would love to hear from you.
Copyright © 2023 - fastn.com