How to use JavaScript in Flutter Apps?

preview_player
Показать описание


👉 Subscribe to our weekly Flutter newsletter:

🖼 Learn Flutter Code Instagram:

🖼 Learn Flutter Code Facebook:

⏰ Timeline:
00:00 - Introduction
02:49 - How to use it
08:34 - How it works
09:56 - Performance - QuickJS
Рекомендации по теме
Комментарии
Автор

Nice! But how about if you have a full js scrip instead of the add() function? rootBundle.loadStrig() won't work as-is. How do we select the desired function inside a class?

romeubeatotech
Автор

Thanks a lot man!! I had learned javascript recently and really appreciate your efforts!! This is the perfect video to understand the case of using js in flutter!! You deserve more subs buddy!!!! And also you got a new SUB!!!!

preadsy
Автор

flutter_js cannot be executed in an Isolation. How does this library run in isolation? This library also has problems on Samsung, Sony, and other devices.

Pepelui
Автор

I'm trying to follow your example using my own JS lib,  
but getting ERROR: undefined is not an object (evaluating 'global.window.define') on iOS,  
TypeError: cannot read property 'define' of undefined on Android. 
Any suggestions would be appreciated.

cbeeapps
Автор

Hi @Learn App Code, You have any idea of package which works for all three web, ios and android ?

abhishekranjan
Автор

can you give me the source code
of this app

officialtrapremix
Автор

What if we have a js file which has 100 functions in it. When I use it like the way you show I get an error like ReferenceError: 'functionName' is not defined, what did I do wrong or how should I do that, thanks.

muharremacikgoz
Автор

I am getting the following error - type QuickJsRuntime2 is not a subtype of JavascriptCoreRuntime

rusiraliyanage
Автор

hey, I tried to integrate JS lib into my flutter app,
but getting `TypeError: cannot read property 'define' of undefined` 
for the following line in the JS bundle `if (typeof global.window.define == 'function' && global.window.define.amd) {`
Any ideas what's wrong? 
Very same JS bundle works fine for me for the native android app.

alisafodorov
visit shbcf.ru