booleanbites / houzi-support

Support forum repo for issues & bugs reported for Houzi Flutter App.
4 stars 0 forks source link

Hooks error on apk build #94

Closed ePento closed 9 months ago

ePento commented 9 months ago

hello ,, i got this error

lib/hooks_v2.dart:870:16: Error: The method 'Conatiner' isn't defined for the class 'HooksV2'.
 - 'HooksV2' is from 'package:houzi/hooks_v2.dart' ('lib/hooks_v2.dart').
Try correcting the name to the name of an existing method, or defining a method named 'Conatiner'.
        return Conatiner(
               ^^^^^^^^^
Target kernel_snapshot failed: Exception

===============================================

here is the code in hooks_v2.dart

  if (hookName == 'new') {
        return Conatiner(
          height: 120,
          child: Text("<h1>Abou Us</h1> <p>dsdsdsddsdssdds</p>"),
        );
      }

==============================================

AdilSoomro commented 9 months ago

Hi, there was a typo, which made Container to Conatiner.

Please fix it by changing to correct spelling.

ePento commented 9 months ago

thank you sir ,, it works but i have problem ,, in text variable i put html code ,, but it shows as it is app ,, should i replace text with child: Html ? i just need simple code to insert html tags and compile it ,, thank you

AdilSoomro commented 9 months ago

Hello,

Yes, will replace Text widget with some Html widget.

Since the hook return a widgets, you can return any complex widget with any child inside it.

You can follow tutorials that shows how to use Html in widget in the flutter.

Look at different approaches here: https://stackoverflow.com/questions/53815485/how-to-show-html-string-in-text-widget-flutter

AdilSoomro commented 9 months ago

Do you need any more help here?