One year of Phoenix Forums!
#10
The problem, for me, with QBJS is that it's more JavaScript than it is BASIC.  Take a look at the last example shared of it in our forums:

Code: (Select All)
Dim img
img = _LoadImage("https://images01.military.com/sites/default/files/styles/full/public/2021-04/chucknorris.jpeg.jpg?itok=2b4A6n29")
_PutImage , img
_Fullscreen

Do
    _Delay 2

    Dim result As Object
    result = Fetch("https://api.chucknorris.io/jokes/random")

    If result.ok Then
        Dim obj As Object
        obj = JSON.parse(result.text)
        Say obj.value   
    End If
Loop


Sub Say (text As String)
    $If Javascript Then
        var synth = window.speechSynthesis;
        if (synth) {
            var utterance = new SpeechSynthesisUtterance(text);
            synth.speak(utterance);   
            while (synth.speaking) {
                await QB.sub__Delay(.5);
            }
            success = -1;
        }
    $End If
End Sub

Dim result As Object   <-- What type is an Object?  It's not one from BASIC

result = Fetch(...)  <-- What command is Fetch?  It's not one from BASIC

IF result.ok THEN  <-- Apparently result is a type with a subtype in it?  Again, this isn't from BASIC..

obj = JSON.parse(...)  <-- Another not BASIC

SUB say  <-- The contents here are 100% Javascript; not BASIC



Not to look down on dbox's creation or anything, but from what I can see, it seems like it'd be almost as simple to just learn JavaScript itself, rather than having to learn JavaScript + QBJS as a front-end engine.  

BASIC is an oooold language, for old-time programmers, and for me personally, QB64PE does exactly what I want it to do for me.  I don't care about having code I can copy and carry over into every browser out there in the world.  As a point of fact, I don't generally even care for most browser-based games or applications out there.  Sure, it's convenient to be able to tap on the phone or iPad and quickly type in a note or read a webpage, but it's just not that great for things that I actually like to do with my PC.  As long as QB64PE can take my code (QB45 + more memory + graphics + modern quality of life stuff) and turn it into a working EXE which I can run from my home machine, I'll stick with it.  Believe it or not, but I've got two different PCs here at home which don't ever connect to the internet, and as such they have no browser installed on them.  An EXE works and plays just fine for me on those PCs, but QBJS wouldn't be much use at all in that situation.

Different tools for different folks, and that's what's great about all these different projects -- folks can pick and choose what's best suited for their own needs.
Reply


Messages In This Thread
One year of Phoenix Forums! - by mnrvovrfc - 04-21-2023, 03:42 PM
RE: One year of Phoenix Forums! - by SMcNeill - 04-21-2023, 05:10 PM
RE: One year of Phoenix Forums! - by Wiggums - 05-07-2023, 09:33 PM
RE: One year of Phoenix Forums! - by bplus - 04-21-2023, 05:16 PM
RE: One year of Phoenix Forums! - by SMcNeill - 04-21-2023, 06:09 PM
RE: One year of Phoenix Forums! - by bplus - 04-21-2023, 06:35 PM
RE: One year of Phoenix Forums! - by vince - 04-21-2023, 10:17 PM
RE: One year of Phoenix Forums! - by Sprezzo - 04-21-2023, 11:22 PM
RE: One year of Phoenix Forums! - by mnrvovrfc - 04-21-2023, 11:41 PM
RE: One year of Phoenix Forums! - by Sprezzo - 04-22-2023, 05:30 AM
RE: One year of Phoenix Forums! - by SMcNeill - 04-22-2023, 11:14 AM
RE: One year of Phoenix Forums! - by Ultraman - 04-24-2023, 01:14 PM
RE: One year of Phoenix Forums! - by SMcNeill - 04-24-2023, 02:27 PM
RE: One year of Phoenix Forums! - by mnrvovrfc - 04-24-2023, 03:11 PM
RE: One year of Phoenix Forums! - by vince - 04-22-2023, 02:30 PM
RE: One year of Phoenix Forums! - by NasaCow - 04-22-2023, 03:10 PM
RE: One year of Phoenix Forums! - by Sprezzo - 04-22-2023, 09:24 PM
RE: One year of Phoenix Forums! - by aurel - 04-23-2023, 05:37 AM
RE: One year of Phoenix Forums! - by Sprezzo - 04-23-2023, 06:09 AM
RE: One year of Phoenix Forums! - by aurel - 04-23-2023, 10:00 AM
RE: One year of Phoenix Forums! - by Kernelpanic - 04-23-2023, 10:58 PM
RE: One year of Phoenix Forums! - by mnrvovrfc - 04-23-2023, 11:16 PM
RE: One year of Phoenix Forums! - by bplus - 04-24-2023, 02:12 PM
RE: One year of Phoenix Forums! - by mnrvovrfc - 04-24-2023, 03:09 PM
RE: One year of Phoenix Forums! - by bobalooie - 04-25-2023, 12:27 AM
RE: One year of Phoenix Forums! - by aurel - 04-25-2023, 07:29 AM
RE: One year of Phoenix Forums! - by Ultraman - 04-25-2023, 04:26 PM
RE: One year of Phoenix Forums! - by mnrvovrfc - 04-29-2023, 10:44 PM
RE: One year of Phoenix Forums! - by DANILIN - 04-30-2023, 11:45 PM
RE: One year of Phoenix Forums! - by Kernelpanic - 05-01-2023, 01:22 AM



Users browsing this thread: 7 Guest(s)