add i18n support

This commit is contained in:
kkzzhizhou 2021-11-21 22:13:19 +08:00
parent e45182547f
commit 1b468b8454
16 changed files with 72 additions and 16 deletions

View file

@ -1,10 +1,11 @@
import * as React from "react";
import HabitItem from "./HabitItem"
import { useTranslation, Trans, Translation } from 'react-i18next'
export default function Index(props: any){
if(props.habits == undefined) {
return (<div id="classDisplay">
No habits present.
<Trans>No habits present.</Trans>
</div>)
}
else {