markdown_styled_widget 0.0.1+3 copy "markdown_styled_widget: ^0.0.1+3" to clipboard
markdown_styled_widget: ^0.0.1+3 copied to clipboard

Widget for parsing and showing markdown markup with your own custom styles

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:markdown_styled_widget/UI/markdown_styled_widget.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatefulWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  State<MyApp> createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  String text = '';

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: const Text('Plugin example app'),
        ),
        body: Padding(
          padding: const EdgeInsets.all(16.0),
          child: Column(
            crossAxisAlignment: CrossAxisAlignment.start,
            children: [
              Expanded(
                child: TextField(
                  keyboardType: TextInputType.multiline,
                  maxLines: null,
                  onChanged: (v) {
                    setState(() {
                      text = v;
                    });
                  },
                ),
              ),
              const Divider(thickness: 5),
              Expanded(
                  child:
                      SingleChildScrollView(child: MarkdownStyledWidget(text))),
            ],
          ),
        ),
      ),
    );
  }
}
6
likes
150
points
1
downloads

Publisher

unverified uploader

Weekly Downloads

Widget for parsing and showing markdown markup with your own custom styles

Repository (GitHub)

Documentation

API reference

License

MIT (license)

Dependencies

flutter, flutter_html, flutter_web_plugins, plugin_platform_interface, url_launcher

More

Packages that depend on markdown_styled_widget