Sub6Resources / flutter_html

A Flutter widget for rendering static html as Flutter widgets (Will render over 80 different html tags!)
https://pub.dev/packages/flutter_html
MIT License
1.8k stars 874 forks source link

[MIGARATE] Migrate to latest webview_flutter plugin to 4.0.0 version #1206

Closed bhanuka96 closed 1 year ago

bhanuka96 commented 1 year ago

There is a new version release by webview_flutter team. Can you migrate this plugin to latest?

Follow this guideline to migrate. link

AlexTeamX commented 1 year ago

I think it's no longer maintained

robotoss commented 1 year ago

@bhanuka96 Made changes to support v4

https://github.com/Sub6Resources/flutter_html/pull/1220

Temporarily you can use it like this:

dependency_overrides:
  flutter_html:
    git:
      url: https://github.com/robotoss/flutter_html
      ref: feature/temp_plugin_use
dragongesa commented 1 year ago

can you do with flutter_html_all ? how to overrides flutter_html_all, because everytime i add path it always said Could not find a file named "packages/pubspec.yaml"

@robotoss

bhanuka96 commented 1 year ago

I use flutter_widget_from_html_core plugin instead of this.

robotoss commented 1 year ago

can you do with flutter_html_all ? how to overrides flutter_html_all, because everytime i add path it always said Could not find a file named "packages/pubspec.yaml"

@robotoss

If you need to use tableRender you can use like that:

Add to pubspec.yaml

flutter_html_table:
    git:
      url: https://github.com/robotoss/flutter_html
      path: packages/flutter_html_table
      ref: feature/temp_plugin_use

And to you code:

import 'package:flutter_html_table/flutter_html_table.dart';

Html(customRenders: {tableMatcher(): tableRender()}),
robotoss commented 1 year ago

I use flutter_widget_from_html_core plugin instead of this.

Good alternative, but unfortunately there are projects that I can't refactor to new dependencies right now. So I decided to make a fork with fixes and share it

dragongesa commented 1 year ago

can you do with flutter_html_all ? how to overrides flutter_html_all, because everytime i add path it always said Could not find a file named "packages/pubspec.yaml" @robotoss

If you need to use tableRender you can use like that:

Add to pubspec.yaml

flutter_html_table:
    git:
      url: https://github.com/robotoss/flutter_html
      path: packages/flutter_html_table
      ref: feature/temp_plugin_use

And to you code:

import 'package:flutter_html_table/flutter_html_table.dart';

Html(customRenders: {tableMatcher(): tableRender()}),

I need the flutter_html_all, but seems there is bug in pubspec. So i cant add that

dragongesa commented 1 year ago

i need the videoMatcher

robotoss commented 1 year ago

i need the videoMatcher

Corrected the paths You can use by:

flutter_html_all:
    git:
      url: https://github.com/robotoss/flutter_html
      path: packages/flutter_html_all
      ref: feature/temp_plugin_use
dragongesa commented 1 year ago

cool, now i can. Thanks a lot @robotoss

Sub6Resources commented 1 year ago

Upgraded versions coming out this week if all goes well