Skip to content

Commit

Permalink
fixup! chore(docs): update translation docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ShGKme committed Jan 26, 2025
1 parent 57d6b69 commit 07c7fcd
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,13 +79,11 @@ If you want to work on improving the components it’s best to run the latest co

## 🌐 Translations

Use `t` and `n` functions imported from `@nextcloud/l10n` to display translated strings.

> Note: these functions are replaced with [`@nextcloud/l10n/gettext`](https://nextcloud-libraries.github.io/nextcloud-l10n/modules/_nextcloud_l10n_gettext.html) on build time.
Use `t` and `n` functions from `src/l10n.js` to display translated strings. They follow `gettext` and `ngettext` interface from [`@nextcloud/l10n/gettext`](https://nextcloud-libraries.github.io/nextcloud-l10n/modules/_nextcloud_l10n_gettext.html).

```vue
<script setup>
import { t } from '@nextcloud/l10n'
<script setup lang="ts">
import { t } from '../../l10n.js'
</script>
<template>
Expand All @@ -102,7 +100,7 @@ Our awesome translation community will then be notified and a bot will sync tran
npm run l10n:extract
```

## 🐸 Styleguide
## 🐸 Styleguidist

When developing new components or extending components, make sure to also have some bits of related documentation like examples, where applicable.
To test components and the documentation in that context, you can run `npm run styleguide` to run a local server that serves the style guide
Expand Down

0 comments on commit 07c7fcd

Please sign in to comment.