this is auto generated from API :)
Go to file
iamstanlee 79d192a441 test: use isTrue/isFalse matcher 2021-06-04 04:47:34 -07:00
example updated readme 2021-06-03 22:22:06 -07:00
lib fix pub warnings 2021-06-03 20:33:01 -07:00
test test: use isTrue/isFalse matcher 2021-06-04 04:47:34 -07:00
.gitignore initial commit 2021-06-03 13:00:21 -07:00
.metadata initial commit 2021-06-03 13:00:21 -07:00
CHANGELOG.md updated readme 2021-06-03 22:22:06 -07:00
LICENSE initial commit 2021-06-03 13:00:21 -07:00
README.md test: use isTrue/isFalse matcher 2021-06-04 04:47:34 -07:00
pubspec.lock initial commit 2021-06-03 13:00:21 -07:00
pubspec.yaml updated readme 2021-06-03 22:22:06 -07:00

README.md

linkfy_text

A lightweight flutter package to linkify texts containing urls, emails and hashtags.

issues] pub package

final

Usage

// first import the package
import 'package:linkfy_text/linkify_text.dart';

LinkifyText(
    "This text contains a url: https://flutter.dev",
    linkStyle: TextStyle(color: Colors.blue, fontSize: 16),
    onTap: (link) {
        /// do stuff with `link`
    },
);

Be default, The above snippet would linkify all urls in the string, you can choose whatxw type of link to linkify by passing the linkTypes parameter

LinkifyText(
        "This text contains an #hashtag and a url",
        linkStyle: TextStyle(color: Colors.blue, fontSize: 16),
        linkTypes: [LinkType.url, LinkType.hashtag]
        onTap: (link) {
            /// do stuff with `link`
        },
    );