File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
src/content/docs/paper/dev/api/component-api Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -45,7 +45,7 @@ some.translation.key=Translated Message: {0}
4545```
4646
4747``` java
48- TranslationStore store = TranslationStore . messageFormat(Key . key(" namespace:value" ));
48+ TranslationStore . StringBased< MessageFormat > store = TranslationStore . messageFormat(Key . key(" namespace:value" ));
4949
5050ResourceBundle bundle = ResourceBundle . getBundle(" your.plugin.Bundle" , Locale . US , UTF8ResourceBundleControl . get());
5151store. registerAll(Locale . US , bundle, true );
@@ -57,10 +57,10 @@ is created from a bundle located on the classpath with the specified [`Locale`](
5757Finally, that ` ResourceBundle ` is added to the store. That store is then added as a source to the ` GlobalTranslator ` .
5858This makes all the translations available server-side.
5959
60- Now you can use translation keys in translatable components.
60+ Now you can use your translation keys in translatable components.
6161
6262``` java
63- final Component message = Component . translatable(" some.translation.key" , Component . text(" The Argument" ))
63+ Component . translatable(" some.translation.key" , Component . text(" The Argument" ))
6464```
6565
6666This will show to clients using the US English language: ` Translated Message: The Argument ` .
You can’t perform that action at this time.
0 commit comments