[Hidden-tech] Help me rewrite an old Programming / Web Development Curriculum? CMS, Language, Frameworks

Tim Boudreau niftiness at gmail.com
Mon Sep 11 15:58:27 EDT 2017


My two cents, having done this stuff for years, and now as the CTO (read:
only developer) of an embryonic startup, and facing framework and tech
choices myself (and being a framework author in addition):

I'd lean towards NodeJS + Meteor/Apostrophe, then Python + Django - same
choices Chaim suggested, just with reversed order.  Other thoughts:

 - PHP is a ghetto.  A very big ghetto, but a hard one to get out of.  It's
not going to give someone real programming skills, and will probably leave
them with a bunch of stuff to unlearn if they want to go on to do something
real.  https://eev.ee/blog/2012/04/09/php-a-fractal-of-bad-design/

 - Consider MongoDB as an alternative in that NodeJS stack (you've got it
if you're doing Meteor).

 - Consider Postgres as an alternative to MySQL.  There's a pathology in
open source software that, if you have something that barely works, people
blog and crow about it when they get it to work - so technologies that kind
of work but not quite wind up looking more popular and attractive than ones
that quietly just work.  Somewhere I have MySQL a t-shirt from a conference
with "[x] TRANSACTIONS" on the back - as in "woo hoo, we've finally got
transactions!" (yes, it's an old t-shirt).  I know, I know, Facebook uses
MySQL - yes, but they rip the SQL front end off of it completely and just
use the storage back end as a giant shared hard drive.

 - If you want to start them simpler in NodeJS, take a look at
https://hapijs.com/ as a sane, straightforward application framework for
basic HTTP stuff

 - Java - there are some good, modern async frameworks out there - but I
wouldn't start with Java - it's not going to provide instant gratification,
and it's too easy to wind up veering into Java EE land, which is a slightly
less squalid ghetto than PHP - but similar in its ability to handicap
people into not being able to think outside its box.

I'll disagree with Chaim about event driven architecture (and thus Node)
being too hard, vehemently:

There is no simpler expression of how just about any piece of software
works than "when this happens, do that".  When an http request comes, call
to this function.

We might think of that as hard because *we* were raised in a paradigm of
writing sequential, synchronous programs that ran on a single-core,
single-threaded 8086.  And some time in the 90s, with multicore processors
and server-writing becoming mainstream, languages and frameworks started
libraries through hoops to preserve the fiction that you're running on an
8086 at all costs, and of course, if you're doing I/O, nothing else could
possibly be happening - in a world that was increasingly diverging from
that.  Thus you get the thread-per-socket paradigm - all to cosset you away
from reality - at enormous cost in resources and scalability.

So in short, evented architecture is *only* only hard to reason about if
you've been handicapped by being weaned on sequential, synchronous
programming.  *Our* generation has that handicap or has had to work to
overcome it.  There's no reason to inflict that on another generation.

There's nothing intrinsically harder about "when this happens, do that" -
human brains are well adapted to that kind of reasoning - if we weren't, we
wouldn't be able to do things like drive cars.  The idea that this stuff is
difficult is a handicap that we don't have to pass to the next generation.

I'd start them on NodeJS, with something really, really simple - just
create a hello world HTTP server (about 8 lines).  Then pick it apart, and
come up with more things you'd like it to do.  When it needs to do more
than one thing, start breaking out functions to do those things - actually
introduce the concept there.  I.e. you start with:

const http = require('http');
http.createServer(function (req, res) {
    res.writeHead(200, {
        'Content-Type': 'text/plain; charset=UTF-8'
    });

    res.end('Hello world');

}).listen(8080, "");

Then show how you can use the request's uri to decide what to say - start
with letting someone go to /Joe and have it say "Hello Joe".  Once you have
a few things in there (hint: use the URL query string) - let it get messy,
so students can see *why* you'd want to do that - show how you could move
each piece out into a function and just add a switch(req.uri) to choose
what to call.

The point is, what's happening in here is simple, low on boilerplate, easy
to write - but it's not hiding the reality of what a server actually does
behind some artifice.  You can then teach frameworks that make this or that
easy, but start with something that gives an understanding of the reality
behind it all - which is really just "when this happens, do that".

Then look at some other things you could use that for - for example, here's
a tiny Node project that simply takes the image-to-svg conversion program
Potrace and turns it into a web service:
https://timboudreau.com/files/trace-service.js - (an older version of that
actually running here - https://timboudreau.com/trace if you want to see
what it does).

If you want some help working up a few initial lessons on this stuff, let
me know.

-Tim


Hi, Folks.
>
> I just got a job teaching Programming and Web Development at Pathfinder
> Vocational Technical High School in Palmer.  I love the kids and it's
> wonderful.
>
> I need to immediately re-do the old curriculum, however.  They were
> learning Dreamweaver DHTML (so some Javascript).  They learned no
> databases. They developed project websites with Adobe Muse (the Anti-Coder
> web tool). And they can't afford Dreamweaver when they leave school, so all
> of this was dead-end.
>
> There are three types of students: those who want to be web developers,
> those who want to be coders, and those who like computers and want to learn
> more.  They are at all different levels ... so I have to balance what would
> best set them up to be coders (few will be) with what will best get them
> doing SOMETHING.
>
> The AP Computer Science test is in Java. Last year ONE student out of 10
> seemed ready to take it after learning it from a textbook (said the teacher
> who left).  The others tried to learn from textbooks and failed.  Obviously
> Java is quite valid to learn ... but what entry level work in Java can they
> find?  And how to connect it to web development?
>
> Obviously they need to learn together, from a teacher (supplemented by
> online courses like Udacity) - not from textbooks.  I need a coherent,
> cumulative curriculum that goes deep into coding, and addresses both the
> back end and the front end. Ideally we also learn a CMS so everyone can
> make SOME kind of website without Dreamweaver.
>
> I think I need to teach them:
>
>    - a server-side coding language - either PHP (because Wordpress),
>    Node.js (because Javascript), Java (because AP Computer Science) or Python
>    (because Python)
>    - a database to connect the language to - MySQL (because Wordpress) or
>    PostgreSQL (because Python)
>    - an associated framework to get comfy with - Symfony (because Drupal
>    and Laravel), etc.
>    - a CMS to get them started - Wordpress (because jobs) ...
>
> What is my best grouping of the four?
>
>    1. *PHP / MySQL / Symfony / Wordpress:* enough PHP to make templates
>    and theme files. Many folks want to hire Wordpress developers. But
>    Codecademy says PHP is so unpopular now that they won't update their course
>    in it.  I can't find anything on the web about what php framework Wordpress
>    was developed from, but http://www.hongkiat.com/blog/
>    best-php-frameworks says Drupal used components from Symfony, and that
>    Laravel is based on Symfony.
>    2. *Java / MySQL / SpringMVC / dotCMS*: only two dotCMS developer jobs
>    on Glassdoor makes me think that won't help them get jobs... but maybe that
>    doesn't matter.  SpringMVC seems to be the most popular Java framework.
>    3. *NodeJS / MySQL / Meteor / [Apostrophe]: *nobody is looking for
>    Apostrophe.  But since we're parlaying Javascript into Node.js and everyone
>    wants to hire mobile app developers, maybe I should push them and leap off
>    the Wordpress bandwagon, leaving Apostrophe for students who can't hack the
>    coding?   Meteor seems to be the most popular Node.js framework.
>    4. *Python / PostgreSQL / Django / Wagtail*: The problem is that none
>    of these connect to the Javascript or Java that we know have to be part of
>    the course, and that unlike Wordpress, Wagtail is not a way to get jobs.
>
> It's better if they know how to do SOMETHING well than how to do many
> things poorly. What would you advise?
>
> Please vote -- and if you have time to explain why, do!
>
> Thanks,
>
> -Bram
> --
>
> Martin Bram Moreinis, Designer/Developer
> http://myinstructionaldesigns.com
> (413) 829-0355
>
> _______________________________________________
> Hidden-discuss mailing list - home page: http://www.hidden-tech.net
> Hidden-discuss at lists.hidden-tech.net
>
> You are receiving this because you are on the Hidden-Tech Discussion list.
> If you would like to change your list preferences, Go to the Members
> page on the Hidden Tech Web site.
> http://www.hidden-tech.net/members
>



-- 
http://timboudreau.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.hidden-tech.net/pipermail/hidden-discuss/attachments/20170911/30809ed1/attachment-0001.html 


Google

More information about the Hidden-discuss mailing list