translated_text 0.0.2 icon indicating copy to clipboard operation
translated_text: ^0.0.2 copied to clipboard

A new Flutter package to translate string into choosen language.

translated_text #

A wrapper on the translator: ^0.1.5 package.

*Note #

  • It can be used to internationilize your app but not recommended for production.

A TranslatedText() widget that displays text to choosen translated language.

Getting Started #

Add this to your pubspec.yaml file.

   dependecies:
       translated_text: 'latest-version'

Import the package into your package.

import 'package:translated_text/translated_text.dart';

Usage #

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp( title: 'Material App',
      home: Scaffold(
        appBar: AppBar(
          title: Text('Material App Bar'),
        ),
        body: Center(
          child: Container(
            child: TranslatedText('I love Flutter',to:'hi'),
            // it will be printed in hindi.
          ),
        ),
      ),
    );
  }
}

Bonus #

  • You can also use JumpingProgressIndicator() widget into your app.

License #

MIT License

Copyright © 2020 Lalit Jarwal

Disclamer #

This package is developed for educational purposes only. Do not depend on this package as it may break anytime as it is based on crawling the Google Translate website. Consider buying Official Google Translate API for other types of usage.

7
likes
110
pub points
65%
popularity

Publisher

unverified uploader

A new Flutter package to translate string into choosen language.

Repository (GitHub)

Documentation

API reference

License

Icon for licenses.MIT (LICENSE)

Dependencies

flutter, translator

More

Packages that depend on translated_text