https://linen.dev logo
Join DiscordCommunities
Powered by
# haxe-ui
  • p

    powerful-morning-89

    05/17/2023, 9:43 PM
    Heaps for instance has a dummy backend: I have one too in my engine:
  • h

    happy-agent-4114

    05/17/2023, 9:44 PM
    ^^
  • b

    bright-gpu-74537

    05/17/2023, 9:44 PM
    next you'll be telling me haxeui-blank doesnt show anything 🙂
  • h

    happy-agent-4114

    05/17/2023, 9:44 PM
    I put dummy parts in anything with multiple parts
  • h

    happy-agent-4114

    05/17/2023, 9:44 PM
    > > ian heeeeeeeeeelp i cant compile my module for haxeui-blank
  • b

    bright-gpu-74537

    05/17/2023, 9:45 PM
    i mean, thats all fine, but i like the error, its valid, it means you've done something wrong (ie, not include a backend)... hiding that will just lead a whole different set of issues, ones without errors... "nothing is showing"
  • p

    powerful-morning-89

    05/17/2023, 9:47 PM
    > it means you've done something wrong (ie, not include a backend)... Yes, but the error doesn't say "You didn't include a backend". It says "some type is missing have fun figuring out what's going on". Which is why a dummy file with an error message might be useful. (Only problem is that if you include a backend before including haxeui-core the dummy file might override the actual file.)
  • b

    bright-gpu-74537

    05/17/2023, 9:48 PM
    "Type not found: ComponentImpl" is a fuckton clearer than "i included haxeui-core but nothing is showing"
  • p

    powerful-morning-89

    05/17/2023, 9:49 PM
    > a dummy file with an error message might be useful. Ie
    #error "No backend found, add -lib haxeui-<backend> to your hxml"
    , which will trigger a compilation error showing that error message.
  • b

    bright-gpu-74537

    05/17/2023, 9:50 PM
    how will you determine no backend is included?
  • p

    powerful-morning-89

    05/17/2023, 9:51 PM
    By putting that error in a dummy
    ComponentImpl.hx
    in haxeui-core. The only problem is that this might not work well if the user includes
    -lib haxeui-foo
    before including
    -lib haxeui-core
    .
  • b

    bright-gpu-74537

    05/17/2023, 9:51 PM
    > (Only problem is that if you include a backend before including haxeui-core the dummy file might override the actual file.) exactly
  • b

    bright-gpu-74537

    05/17/2023, 9:52 PM
    so, "haxeui-html5" before, or after, haxeui-core could trigger an error
  • p

    powerful-morning-89

    05/17/2023, 9:52 PM
    Just thought of something: in each backend have an
    extraParams.hxml
    with
    -D haxeui_has_backend
    . Then you could do
    Copy code
    hx
    #if !haxeui_has_backend
    #error "..."
    #end
  • b

    bright-gpu-74537

    05/17/2023, 9:52 PM
    throwing the baby out with the bathwater... better to let the compiler deal with it
  • h

    happy-agent-4114

    05/17/2023, 9:53 PM
    that seems really overcomplicated
  • b

    bright-gpu-74537

    05/17/2023, 9:53 PM
    but why? this is over engineering... the error is clear... it indicates there was no backend included, and there wasnt
  • b

    bright-gpu-74537

    05/17/2023, 9:54 PM
    solution: include a backend... would a super nice error message be nice? I mean, i guess, sure, but if you are using a lib and it says another lib (that is required) doesnt exist... what do you want?
  • p

    powerful-morning-89

    05/17/2023, 9:56 PM
    > it says another lib (that is required) doesnt exist But that's not what the error message says. All it says is
    Type not found: haxe.ui...
  • h

    happy-agent-4114

    05/17/2023, 9:57 PM
    also it doesn't actually throw
  • b

    bright-gpu-74537

    05/17/2023, 9:57 PM
    anyways, suffice to say, use haxeui without a backend, you'll get compiler errors, thats fair i think... i get the structure of haxeui doesnt make that clear, but well, i dont know...
  • h

    happy-agent-4114

    05/17/2023, 9:57 PM
    it shows zero problems because the language server doesn't actually start
  • p

    powerful-morning-89

    05/17/2023, 9:57 PM
    You should get a little popup in vscode with a button to take you to the output tab.
  • b

    bright-gpu-74537

    05/17/2023, 9:57 PM
    right? something something something backend
  • h

    happy-agent-4114

    05/17/2023, 9:58 PM
    should, yes. do? no
  • p

    powerful-morning-89

    05/17/2023, 9:59 PM
    Again, how is a normal user who doesn't know about the internal architecture of haxeui supposed to know that?
  • b

    bright-gpu-74537

    05/17/2023, 9:59 PM
    maybe im living on a different planet, but isnt this plain as day:
  • b

    bright-gpu-74537

    05/17/2023, 9:59 PM

    https://cdn.discordapp.com/attachments/565569107701923852/1108514190349578310/image.pngâ–¾

  • h

    happy-agent-4114

    05/17/2023, 9:59 PM
    I should have known more I'm literally writing a module
  • h

    happy-agent-4114

    05/17/2023, 10:00 PM
    I feel like I'm not really the average use case though
1...167416751676...1687Latest