in reply to Perl koan #2300 (Perl in the browser)

I very seriously doubt that you will displace JavaScript anytime soon on the web browser.   And, I personally don’t see Perl as a very good contender because Perl depends heavily (and very successfully) on external, CPAN libraries.   Much as I like the Perl language, I candidly do not see it being a good or easy fit for that scenario.

However, I do not recommend writing source-code directly in JavaScript.   Instead, I would use a so-called “transpiler” which targets JavaScript, among many other targets.   (A “transpiler” is a compiler which produces source-code as its output.)   You are now able to write “correct” JavaScript much faster and more-accurately than you otherwise could, because you now have good compile-time checks, strong typing, and many other features of more modern languages.   (And if you want to turn the same source-code into, say, a native mobile application for any of several(!) platforms ... you can do so.

A system that I think should definitely be on everyone’s radar right now is OpenFL, and also its base-language, Haxe.   (Of course, that is off-topic to this venue.)

Replies are listed 'Best First'.
Re^2: Perl koan #2300 (Perl in the browser)
by karlgoethebier (Abbot) on Apr 20, 2015 at 18:55 UTC
    "I would use a so-called “transpiler”...(A “transpiler” is a compiler which produces source-code as its output.) "

    Do you know a transpiler that converts Basic English to Perl code that compiles?

    Thank you very much for any hint and best regards, Karl

    P.S.: For all with that conditioned reflex: Please see Re: poll ideas quest 2015

    «The Crux of the Biscuit is the Apostrophe»