Friday, October 31, 2014

MakerSquare Day 47: Maybe locking myself in my room with the disease wasn't such a good idea after all (10/4)

I didn't get a lot of work done (or oxygen to my brain) today, which is a little disappointing. (Well, the oxygen thing is slightly more than disappointing.) But it does bring up something--in a round-about way--that I'm not sure I've talked about but which has been on my mind:

Why did I leave writing for code?

Well, I didn't really: I still enjoy writing fiction and plan to continue with it in the future. I just left behind the field of freelance non-fiction writing.

(Except for blogging, which you may notice I've kept to like a barnacle.)

As much as I enjoy writing, so much of it is solitary work. And, as I've been reminded by my unintentional quarantine, code can be solitary--but it can also be team-work. Even if you're not in an organized team, you'll find that an open-plan office leads to some interesting cross-pollination.

At the very least, when I'm at the MakerSquare office, when I hear someone talking about some interesting code--either an interesting solution or an interesting problem--it can sometimes get me thinking about something useful. Or when I run into a problem, there's usually someone around to talk it out, whether the other person provides a solution, a hint, or merely a willing listener while you solve your own problem.

In writing, that's not so much the case. Don't get me wrong: if you're working on something, you may have people you can turn to, whether it's your writing group or just a friend willing to read something. But there's not really that same sense of team-work and collaboration.

And that is one reason why I really don't like being stuck at home, sick, right now; and it's one reason why I decided to move into a coding career: I like teamwork.

Thursday, October 30, 2014

MakerSquare Day 46: Hackathon ::cough cough:: (10/3)

At MakerSquare, Wednesday and Thursday are given over to a hackathon--late nights, food provided, and lots of coding on the second final project.

Here at the DevHouse, my Wednesday and (probably) my Thursday are given over to a lot of cold medicine and vitamin C and tea. It's kind of a bummer in the way that minor illnesses during final project weeks are kind of a bummer. I'm supposed to be working my portfolio now, but instead most of my energy goes into getting tea. (Never again will I take my electric kettle--still at home in San Angelo--for granted.)

Ah well, I guess the only thing I can do now is get better soon.

That said, during my brief lucid moments--when the cold medicine kicked in--I did find an interesting tutorial on using Angular in a Chrome extension.

Wednesday, October 29, 2014

MakerSquare Day 45: Final project #2 -- but really home sick (10/2)

I went home early on Tuesday, since I've caught that cold that's going around. (Or at least, that my housemate has.) So this'll be a short post, with the sound of me sniffling and coughing in the background.

Luckily, Tuesday was the first day of our second final project, and I've chosen a manageable project right now / for once: a Chrome extension that will block spoilers on Twitter.

So I didn't get that much done on Tuesday since my primary goal for the day was to always have a hot tea with me at all times. But right now, here's the minimum viable product plan, some notes on my progress, and some current pain points, along with some extension ideas.

Minimum viable product:

  • The user can engage the extension and type in a word or phrase that'll trigger the blocker, e.g., "Game of Thrones."
  • All tweets with that word / phrase will be hidden (both words and pictures).
  • The user will be able to show any hidden tweet if they choose to by clicking on the hidden tweet.

Some notes:

  • At first I looked into grabbing all the children of the container object in the tweet stream:
    • $('').children()
  • ... but then I realized I could just grab the individual tweets directly (and put them into a variable, which I then iterate over):
    • var tweets = $('li.js-stream-item')
    • for (tweet in tweets)
  • It's not terribly hard to hide the tweets and pictures (though I also thought about other ideas, including detaching the material with .detach() ):
    • $(tweet).find($('.tweet-text')).hide()
    • $(tweet).find($('.js-media-container')).hide()

Some pain points:

  • Right now, I'm having some trouble putting in a button that'll respond to a user's click to show the hidden tweet. When I put something in the tweet space, it acts like a normal tweet acts when clicked, i.e., it expands.
Some extension ideas:

  • It would be super-neat for this extension to block tweets that had the trigger words, but also to find some related tweets to block. So, e.g., if you put in "Game of Thrones," the extension might also block out certain related words like "Red Wedding."
  • It would be (slightly less super) neat for this extension to be platform agnostic, so you could block spoilers in, say, Facebook or elsewhere.

Tuesday, October 28, 2014

MakerSquare Day 44: A different type of hackathon (10/1)

Today we had a hackathon, but not the usual kind. Today was our--

Resume Hackathon!

I'm probably just using bold here to make it sound more exciting. To be clear: the idea of going out on the job market; of going to interviews; of getting my first job in web development--all of that is very exciting to me.

But writing and revising a resume isn't as exciting as embarking on a lifelong career in a field that I'm kinda crazy about.

(Have I ever told you guys about meta-programming in Ruby? It's when you write code that then goes and WRITES MORE CODE. As a long time fan of infinite loops, the idea of code writing code makes me very happy.)

Part of the general (I think) lack of excitement when writing resumes is that resume writing is a lot more cramped than writing code.

Or rather: if I give you a coding challenge, you could probably think of five ways to code out a solution; and if any way fails, you'll get an error message that tells you how to fix it.

Man, I love feedback.

Unfortunately, resumes don't offer the same level of detail in their feedback. You get less "undefined variable" or "stack level too deep" and more "no thanks" and ::crickets::.

For me, with my big change in career from ex-PhD candidate and education writer to programmer, it's interesting to see how much of my resume is no longer relevant. Although maybe I should leave some of that in. Wouldn't you like to work with a web developer who once taught a class on 19th-century science fiction?


(Actually, now that I think about it, I think my teaching experience really does help me with both public speaking and with translating certain concepts into more easily digested forms. So, it's going back in the resume, people! Along with my improv classes at the Second City.)

Saturday, October 25, 2014

MakerSquare Day 43: A very little view of a week's worth of work (9/5)

When we did our hackathon, I was in a team of four people; Kelsey and I had whiteboarded (with our TA Ben's help) the night before and focused on our minimum viable product, with a whole bunch of extension possibilities; and the four of us had pretty distinct responsibilities.

So when I look at my current project and compare it to my hackathon project, I don't feel terrible that this project is not as advanced. I mean, we had 4 * 2 programmer-days for that, while I've only had 5 * 1 so far for this.

That said, I'd like to take the focus off of me for a second--just a second, mind--and talk a little bit about the cool things I've seen my peers make. Now, not all of this is ready for prime-time, but I don't think anyone would mind me talking about, for instance--

A neat little web app for playing pong (all in JavaScript);
The neat front-end design of a recipe box (with some very nicely done CSS);
The figuring out of the interface with Yelp API or Twitter API;
A large content management system service;
A well-constructed financial modeling system;
A way to get info from that pays attention to the performance issues;
A front-end only collection of math/science tools with a really nice panel system;
A neat list-sharing app with a great in-place editing system;
The updated and improved version of the hackathon flash card app and the ping pong tournament app.

Like I said, they're not all done. But when I look back at what my peers have done before and see what we're capable of doing now, I'm very proud.

Bonus: yesterday we had a meeting with some people from Ivity Labs, an offshoot of SpringBox, including a MakerSquare alum; and today we had a MakerSquare alum from Lou Malnati's in Chicago come by. All of which adds up to this:

When we started, we weren't that good; now, we're a whole lot better; and with just a little more experience, we have the capacity to be a whole heck of a lot better.

Friday, October 24, 2014

MakerSquare Day 42: Stone on stone--until ... (9/4)

I don't have anything to show you right now. I'm not entirely sure when I will. (There's a possibility that I don't have any website to show you to, but only some screenshots since we build most of our apps on our computers; porting these local "sites" to other sites can be done, but may not be worthwhile at this stage.)

But rest assured, when you spend several days moving stones, eventually you will have...

... something resembling a pile of stones.

That might not sound like much, but I'm actually very excited. Because--and watch this metaphor of stones get extended--sometimes it can feel like you're hitting your head on a stone wall and not accomplishing very much. But sometimes some stones get dislodged with enough hitting. And then you might notice that some stone that you're looking at is actually the perfect shape to rest on this other stone that you just happened to be looking at.

(I don't want to over-dramatize the importance of happenstance and luck; but if you've spent as much time in libraries as I have, you know sometimes the important book is right next to the book you went to find. Almost the same could be said for coding: you can go research AJAX calls and instead find a cool Ruby gem for editing in place.)

All you need is time, a head hard enough to survive repeated pummeling, and the will (and curiosity) to keep going on moving stone after stone.

(To be more--ahem--concrete, today we learned about Promises in JavaScript (which is a way to chain asynchronous calls); and I got my database tables all re-written to do what I know think they should do.)

Thursday, October 23, 2014

MakerSquare Day 41: Commas; or, Masonry, Part 2 (9/3)

Oh, I remembered the joke I was going to use yesterday--and it wasn't actually that good.
Oscar Wilde comes into the pub at lunch, looking exhausted.
"Hard morning of work?" asks the publican.
"Yes," says Oscar, "I spent all morning putting a comma in."
Oscar has lunch, leaves, and comes back for dinner, looking exhausted.
"Hard afternoon of work?" asks the publican.
"Yes," says Oscar, "I spent all morning taking that comma out."
There are (as I've said before) some big similarities between comma world and coding world; and, in fact, a lot of today has felt like some version of this Wilde joke. Like:
"Oh, I should add in a section on all pages that will be blank unless there's been an error and that section could report the error."
Then, later:
"Hey, I just implemented a section for good messages under my section for error messages. Why not just make a section for messages and pass in any messsage--good or bad?"
That's not the only example of an added comma/removed comma shuffle. And I won't lie, I understand why Wilde might be so exhausted after a morning and afternoon wrestling with a comma. He feels--and I feel--exhausted because it is exhausting.

So why keep doing it? Because Wilde and I are secretly masochists who like torturing ourselves? No. Well, maybe a bit of that. But mostly because this thing that we're so exhausted by--we're making it better by playing with it.

Alternate possibility: Maybe Wilde just didn't know how to use a comma correctly?

Wednesday, October 22, 2014

MakerSquare Day 40: Masonry (9/2)

I thought of a really funny--and also insightful and humane and most of all, humble--joke to start off today’s post; but it was quickly forgotten during today’s grind.

“Grind" might be the wrong word to describe today’s work on my final project #1. When I hear “grind,” I imagine one stone … ::looks up synonym for “grind”:: … pulverizing another. Slowly, thoroughly, with great and terrible purpose. So after a full day of grinding, I expect a lot of dust and debris--and not a lot of stone.

Whereas today, yes, there was some dust and debris (some rejected bits of code and collections of bookmarked websites answering questions I'm no longer asking). But at the end of the day, there were a few more stones on stones than there were yesterday.

Which is why today’s title is “masonry.” It’s not a romantic, fantastic word. No one raises a flag for masonry. (Well, except maybe the Masons.) 

But masonry gets stuff done.

For instance, I figured out how to alter an ActiveRecord database table when I'd already added an email column and needed to re-add it to use the Devise gem's authentication capabilities. (The secret is t.change in your migration.) That said, today was also the day when I realized that security is not part of my minimum viable product.

Maybe "minimum viable product" should really be today's title. Or maybe I should go with my first choice and just get that tattooed on my hands so I always remember.

Because masonry gets stuff done, but it takes time.

Tuesday, October 21, 2014

MakerSquare Day 39: ...but implementation is hard (9/1)

Last Friday was a reminder that ideas aren't all that hard to come by. (Especially when you are a student and can feel free to, you know, steal from major companies and try to do it yourself. Because, honestly, my version of Facebook isn't meant to compete with Facebook, but merely demonstrate that I could make one.)

But today, Monday, was all about how putting ideas into practice is hard. Because today, I started to work on my first final project.

I'm calling it ShareCare: a web-based, mobile-ready(?), team-based app for sharing caretaking duties and keeping track of those duties.

And yes, it was inspired by the fact that my girlfriend and I sometimes need to communicate about whether the dog's been out and pooped (or as we say, "was productive").

So, in honor of the difficult process of implementing the (pristine, beautiful, unsullied) idea, here's some photos of notes I made as I attempted to chart out my path on ShareCare.

1) Minimum viable product:
Here's a reminder when doing, well, just about any product. You may be making something incredible, but you start with a deadline and a minimum viable product. Anything that's cool that's not part of the minimum viable product goes into the bucket.

2) "Weeks of programming can save hours of planning":
That's an old coding joke; it's also the reason why I didn't write a line of code until I had mapped out my database and the relations between these entities. (Note: And I still had to go back to change a few things!)

3) Don't be afraid to make mistakes:
If we were supposed to do everything right the first time, we wouldn't have invented erasers. Or, in my case, invented more ink to cross out things--and then even more ink to re-write what I crossed out.

Let's see what I can show you tomorrow.

Saturday, October 18, 2014

MakerSquare Day 38: Ideas are cheap (8/5)

I've said it before--and gotten some annoyed looks about it--but I'll say it again: ideas are cheap.

Note: I say "ideas," not "good ideas."

But even with that caveat, I feel like my training in creative and non-fiction writing gives me a perspective on idea-generation that could get me some annoyed looks. So, to be clear:

When I say "ideas are cheap," I don't mean, "Ideas are cheap for me, I have a million ideas, they just come to me like a friendly bird":

I mean "ideas are cheap for everyone."

Sure, some people have blocks or difficulties--like the block where they tell themselves that they are not all that creative.*

*Sidebar: OK, I have three experiences that give me a different perspective on idea-generation:
  1. my grad school career, where I both had to come up with paper topics and teach students how to come up with paper topics;
    • killer question: "what's weird about this book?"
  2. my creative writing hobby, where I kept long lists of things that sparked ideas;
    • killer habit: writing everything down--everything from full-blown ideas, to notes on characters/settings, to single lines of dialogue, to single words that seemed stuffed with potential;
  3. my roleplaying/gaming life, which taught me that I could come up with ideas;
    • killer experience: playing a game recently with another MakerSquare student who started out saying "I have no ideas" and ended the game with "what if this happened? What if this other thing happened?"
End sidebar.

But really, if you don't self-sabotage by telling yourself that you have no ideas, I'm sure everyone can come up with a bunch of ideas. (Remember: I'm not saying these ideas are good.)

You could start with thinking about your day: what would make any area of your day a little better? What would help anyone you know?

Now branch out from there into things you're interested in: What would someone you know really enjoy? What's something that's cool? What's something that I'm passionate about?

Think also about the techniques and tools you might use: What's something that's challenging? [Note: this is an especially great question for creative writing.] What's something that's almost inside my comfort zone but not quite? What's something that I can do to show off a little?

Take a lesson from Tina Fey and her book Bossypants (or better yet, take a lesson from the improv classes that you took--because everyone should take improv classes): at this stage, just write down the ideas, without judging them.

See? Ideas are cheap.

Friday, October 17, 2014

MakerSquare Day 37: Double your time projections (8/4)

Today we talked about some issues with our final projects. 

The first idea of which is we will be responsible for several final projects. Which is nice for people like me who (a) have many ideas* and (b) are interested in everything.

The second issue is that, damn, final projects start in a few days.

Third: We need at least one individual project, but our second could be a team project (as long as we have pretty strict separation of concerns, so that we can individually point to a project and say, "I did X on this project, and your company is interested in X, so...").

And fourth, when you scope our your project and think about how many hours it'll take--double that idea, because that's how long it'll take.

So, that's fun.

No, seriously, I can't wait to go through my list of ideas and find some that are (a) doable, (b) interesting, (c) involve interesting technologies, and (d) doable. And yes, "doable" is in that list twice. 

*Note: "many ideas" does not equal "many good ideas."

Thursday, October 16, 2014

MakerSquare Day 36: Zombies, Run! (8/3)

This is going to be a little departure for me in terms of content: instead of talking about our coding challenge (a Caesar Cipher, which was very fun), or what we learned in school (Rails, which is also amazing), I'm going to talk about an app I finally broke down and bought: Zombies, Run!

Here's the pitch: you start the app when you run, and you get messages about what's going on in the world around you--except the world around is overrun by zombies, with ruins and disaster. So you'll get notes about how you picked up supplies, but you'll also get notes about how zombies are chasing you and you have to speed up.

Pretty simple on that end (and we're ignoring the part where you rebuild the town), but effective. I mean, when I run (note: I've run three times in my life), at some point I'm liable to slow down. I could run with other people, but it's hard to find other people who (a) run around your same optimal pace and (b) are around to run when you want to. This way, I carry around a little bit of motivation with me, both for running more often (because the story is fun right now) and for pushing myself (when the zombies are chasing me).

So now, to bring it back to MakerSquare (and our upcoming final project), how do I use this example of a solid product to inspire me?

Or maybe I should just pretend that zombies are chasing me all the time and the only way I can escape is to code? Can I make Zombies, Code!

Wednesday, October 15, 2014

MakerSquare Day 35: Teamwork--without ping pong (8/2)

Last night, I tested a friend's quiz program (a really neat one). This afternoon, a friend helped me debug a use of the Soundcloud API. Earlier this evening, I ran a friend through a white-boarding exercise.

Besides bragging about all the friends I have--three!--I bring up these three stories just because I like them. OK, that's not entirely why. I like those anecdotes because in each I am occupying a different role, sometimes getting help, sometimes giving help (or, in the case of testing the quiz program, sometimes trying to break a friend's code in any way I can. And good news! I am very skilled at breaking code by doing the wrong thing, just like most end-users).

Also and more seriously: because in each, what we make with a little bit of teamwork is better than what we make alone.

Which brings me to the (slightly longer) anecdote I really want to tell you, about our morning coding challenge. (I could tell you about the bulk of today's work, working with Rails, but it's less anecdotable.

Today's coding challenge was to tell if a string was also a palindrome, disregarding non-letters and not paying attention to case. Pretty easy to get a rough version functioning: just downcase the string, use a regex to get rid of everything you don't want, make a copy that you reverse and compare them. Easy peasy--but not very nice.

(Aside: Nothing involving Regex is ever easy.)

One of my very algorithmically-minded peers had a different version, where you set an index at the beginning and at the end, and letter-by-letter, move to the middle of the word, checking that each letter is the same (after downcasing and skipping over non-letters). It was weird-looking, but super-efficient--except that he set a counter that incremented for each letter that matched and at the end of the loop, he checked that the counter was equal to half the string's length.

And suddenly I saw a way that we could skip all that and use a failure case to end the loop early, thus cutting out a few lines of code and stopping the function early if the string wasn't a palindrome. I was so excited by this that I almost ran to the board to ask our instructor if it would work. And here's a paraphrase:

"Together, this class created the most efficient version of this function."

Which I think is pretty neat, especially since we no longer have ping pong to bond us.

(Did I tell you that I miss ping pong?)

Tuesday, October 14, 2014

MakerSquare Day 34: The hard way first (8/1)

First, I've been bad about holding my blogging time to 15 minutes, so I'm back to setting an alarm. So let's see what I can tell you about the Monday of our eighth week in only 15 minutes. (It's so interesting to me how 15 minutes can seem like an eternity--if, say, you're waiting for a bus--or like no time at all if you're trying to get something done.)

(Speaking of buses, I decided not to wait for one last night, and on the walk home, I saw a fox running along the street, which means that I really made the right decision. Have I told you how much I like most animals in the Canidae form? I guess that doesn't really have much place in a coding blog. Unless I can somehow come up with a dog-related coding project...)

Many weeks ago, we learned how to use PostgreSQL to create and access database tables. Which meant that, on top of learning Ruby, we had big chunks of this other language in our code. Then we were introduced to Active Record, which is--ok, this gets a little jargony, but here goes--an ORM (object-relational mapping), or, in less-jargony form: Active Record is a way to write Ruby that will talk to your database in whatever language that database likes to talk.

I've said it before, but Active Record is kind of magical and cool (for at least some value of cool); and the topic was introduced to us with,
"Now that we made you learn PostgreSQL, we're going to teach you this easier way to do things, and you're going to hate us for making you do it the hard way first."
But I really didn't. It was hard to start with PSQL, but doing things the hard way first means that (a) you appreciate the magic of the easy way and (b) you understand what's going on under the hood.

I thought of that yesterday after our first day of Rails. Have you seen Rails? It's kind of amazing how Rails does so much for you. So after weeks of hand-producing files slowly and carefully, now I just type "rails new <Project_name>" and everything appears as if by magic. Which is great and amazing--but I'm still glad that we did it the hard way first, so I can understand what's happening.

Saturday, October 11, 2014

MakerSquare Day 33: Front- and Back-End (7/5)

When I started at MakerSquare, my sister asked if I could make her a website. At that point, we were deep into Ruby, which is not really (at all) what you would want to build a website in.

(Though, to complicate issues, there's lots of Ruby-ish qualities to tools that'll help you build a website, like Jekyll (for generating static websites) and Liquid (a template language that seems a little bit like code) and Sass/Scss (for styling your pages). So, yeah.)

But now, this week we spent two days playing around with HTML and CSS and...

...And I realized I never talked about the front-end/back-end division, which I've mentioned a few times. Is it clear what I mean when I say that? What if I said "full-stack"? (Don't worry, I won't say "full-stack," at least not in reference to my skill-set.)

The general division between front- and back-end is, uh, basically in the name. If you need an analogy, think of the front-end as the client-facing side of just about anything: the salesclerk helping a customer find the right size suit/dress is working front-end. The guy in the back, unloading pallets of clothes and organizing the employees-only room in back? He's doing back-end work.

Or, in honor of my librarian girlfriend teaching me about libraries: the librarian who helps you find a book and checks it out for you is only one small part of the library. In the back rooms, doing the back-end work, there are a lot of librarians doing the cataloguing and dealing with the rarer customer requests (like interlibrary loans).

In web development, that division of labor (or separation of concerns) comes out in the separation of back-end logic (how we store data and how we do a lot of work on that data) and front-end presentation (which is how the website is presented to the user and how it responds to that user). There's some overlap--even when I worked as a stockboy at a health-food store, I sometimes helped out customers find the right vitamins for their terrible ailments--but that's the general division between web developers.

So in a few weeks, after working on my sister's website, I'll probably be able to tell you if I like this far front-end work.

Friday, October 10, 2014

MakerSquare Day 32: Stump the Expert and Startup Crawl (7/4)

In his early work, George Carlin has a bit about how kids at his school would get to ask their priest really arcane questions, questions where they would add caveats and issues to try to stump the priest, questions like
"Father, what if you haven't done your Easter duty and it's the last day of Pentecost, and you're on a ship at sea and the chaplain goes into a coma, but you wanted to receive, but now it's Monday and it's too late--but then you cross the international date line..."
And there's a little bit of that when our HTML/CSS expert comes in. Which might be a good signal about how... mysterious HTML/CSS can seem. Like religion (oh boy, watch me step carefully here), there are some things about HTML/CSS that are relatively straightforward. Like: When you create a section (using a <div> tag), the div can be a block (and so take up the full width of the page) or be inline (and so only take up a certain amount of horizontal space) or be an inline-block (and so mix the two presentation-styles).

Actually, now that I think of it, block, inline, and inline-block aren't all that clear.

But there's a lot of info on those differences online and it all sort of makes sense. When you get to some other tags and options, this stuff gets arcane quickly. (Which might serve as a good tagline for MakerSquare: "Get Arcane--Quickly.") So when our HTML/CSS expert comes in, we often have a show-and-tell/stump-the-priest attitude.

"What if you want the text to be 3D and come out to the reader, but not too 3D? What if you want to make an entire section clickable as a link, without wrapping the whole section in a link tag? What if..."

Unlike religion (oh, careful, careful), once you see the answers, most of them don't turn out to be all that arcane. (Or, well, it's been a long time since I was in Hebrew school, but my memory of it is that all the stuff that seems arcane, really is arcane.) It's mostly a question of learning the right words and suddenly you can make 3D text that's actually behind a div container and make that container spin when hovered over.

This evening, MakerSquare--and some other offices--were taken over by the Startup Crawl part of Austin Startup Week, which involved a fair bit of parties and talking to people about their tech stacks. It was interesting to go from "how to present a website" to "how to present yourself as a human being, oh god, talk about something fun like George Carlin."

Overall, it was a good time and I did talk to a lot of interesting people at interesting companies who, though they didn't know it, were assigning me homework every time they talked about something I haven't yet mastered.

Thursday, October 9, 2014

MakerSquare Day 31: A Million Little Tiny Tricks: Trick one: Delegation (7/3)

Today was our last day of our current project, a single-page application that gave the reader a quiz. Simple enough to do (that is, not at all simple when we started), but then we had several extensions and expansions, like: allowing the viewer to create their own quiz. To do so, we learned all about localStorage, which is where we were storing information about the quiz.

Which brings me to something interesting that we discovered as a class (i.e., something the instructor wasn't quite clear on), which is that you can iterate over localStorage as if it were an array-like structure.

Which brings me to the real topic of this blog-post: there are a lot of high-level topics and concepts in learning programming, everything from abstract patterns (like MVC) to language foundations (objects, type-sensitivity, etc.).

But there's also a whole range of tiny details and little tricks that you pick up along the way, that even really smart and experienced instructors might not know. And I'd like to share some of them, as I pick them up.

Yes, finally, after 28 days, I have an idea for an on-going blog feature!

Today's trick isn't really a trick: it's a life-saving idea about JavaScript and event listeners. Beginning developers (cough, cough) often have a problem where they/we create an HTML button and add a JavaScript listener to the button--only that button is added after the event listener and so the event listener can't find the button.

So there's a nice jQuery fix where you set a listener to load after the page loads:
$(document).on('ready', function() {
...your listeners here...
 But you can also delegate the event listener to the document, like so:
$(document).on(...what event you want to listen to, ...what you want to trigger the event... , function( event ) {...}
That way, the event listener is delegated to the document, which will hand it off to whatever you want to trigger the event, and it will work whenever that event-triggering object is added to the document.

Wednesday, October 8, 2014

MakerSquare Day 30: Quiet room, loud room (7/2)

Instead of one big room like our Brazos office, the Congress office is, well, one big main room, but with a few smaller rooms coming off of it: we have our own kitchen, a little tv room area, and the Quiet Room.

I'm not sure it's actually capitalized like that, but as a long-time reader of horror, I like it with a hint of sinister. Though it's really not sinister; it used to be the tv room, where people would play Super Smash Bros. and other games from long ago.

But now it's the Quiet Room, where people can go to get away from the hubbub of the main room to get some work done.

I tried it out yesterday when we were continuing on our single-page-application project: a quiz purely written in JavaScript. It wasn't bad. (The room, I mean. My quiz page is also pretty nice, which brings up another issue we should talk about: front-end vs. back-end work.)

But the Quiet Room wasn't quite the productivity silver-bullet that it might sound like. Sure, I could get some reading done in there, but there were a couple of times where I wanted to talk to someone about what I was trying to do or see what they were trying to do.

I was reminded of (I'm always reminded of something) the title of a book about the culture of the Jewish shtetl that I read in college: Life Is With People. Except if I were writing a book about MakerSquare (and coding more generally), I'd title it Work is With People.

It's like what I learned about the culture of creative writing and really successful writers over the last few years: you may do some really great work by yourself, but what really makes it both possible and worthwhile is bringing your writing (fiction or code) to the group, either to get corrected or to show what you learned or just to share.

So maybe I'll leave the Quiet Room for the ghosts that surely inhabit it. I mean, a lot of Super Smash Bros. died in that room.

Tuesday, October 7, 2014

MakerSquare Day 29: First day on the senior side: so much to learn (7/1)

Today was the first day we spent on the senior side, which (as I said before) is both a philosophical shift (towards preparing for our final projects) and a physical shift (moving from our Brazos office to our Congress office).

Which might sound banal, but I'm a big believer in the effects of the built environment on people. So what effect will it have on us, I wonder, now that we've moved from the cod modernism of a big office building, with lots of glass and blank walls (and basement views), to the slightly warmer--but still windowless--office with the painted walls.

And on this day, I was struck with three thoughts.

  1. Biking to the office rather than walking is a lot faster. Probably an obvious observation, but one which was driven home to me since I only now have a bike here in Austin. (My girlfriend recently bought a really sweet hybrid road/mountain bike, but since she's not using it, she let me borrow it.)
  2. We know a fair bit of stuff already. Monday's task was to make a single-page application with a quiz, with a fair bit of wiggle room about what that quiz should be about or how it should be delivered. The goal was to think about MVC design pattern, where the Model, View, and Controller were all given their own design space. And there were lots of fiddly bits and some harder moments, but it all made sense and was doable. So it was striking to me how much trouble we would've had with this just a few days and weeks ago.
  3. There's still quite a bit that we need to learn. Which was less striking as a thought because it's a thought I've had constantly for the last few weeks. After finally really getting the MVC pattern (which I'd heard of before, when I was dabbling in iOS programming), I went to a meetup to hear about functional programming in Ruby. See? There's always more to learn.
Maybe's that's why I like this stuff so much.

Saturday, October 4, 2014

MakerSquare Day 28: Skills on the line (6/5)

Children play "Rock Paper Scissors" in jest, but web developers build "Rock Paper Scissors" apps in earnest. (To paraphrase Bion.)

It's been real interesting to go from some of our smaller, more focused projects--projects where we learned and employed one new technology or section of technology--to something like a full project. Because, even though "Rock Paper Scissors" is a pretty simple game, with a high requirement of two hands, as an app, there's a lot of little pieces.

You'll need HTML and CSS to display the page, with some sort of web app technology, like Sinatra, to host the server and pass info from your front-end to your back-end. Throw in a little Javascript and jQuery to make the site interactive, and you've already gone beyond the technology I had when I made my first website at Geocities. Then, on the back-end, you have Ruby handling the logic and ActiveRecord handling the database to keep track of how players are doing.

Also, at some point you have to grab some silly pictures of rocks, paper, and scissors; or come up with some weird angle to make your Rock-Paper-Scissors game stand-out. (My favorite theme so far is pirates.)

And you have to do all of that before the big, cohort-wide ping pong tournament on Friday. Because no matter how much your skills have improved in terms of HTML, CSS, Javascript, and Ruby, the real judge of a developing developer is ping pong.

Until next week, when we move into our new office. Then the only skills that matter will be coding skills.

And also Super Smash Bros. on the N64.

Friday, October 3, 2014

MakerSquare Day 27: Oh the places they'll go! (6/4)

If I haven't already mentioned this, MakerSquare currently has two classes going in Austin, known as C8 and C9, with C9 beginning halfway through C8's 12-week run. And this is the last time--at least for now--that Austin will be hosting two simultaneous cohorts.

Which is nice in some ways: I won't have to share my room at the DevHouse with anyone from C10; now we get all of the attention from all the teachers.

But it's bad in some ways. For instance, today we went over at lunchtime to see C8's final projects. And they were pretty gosh darn good. I mean, I was proud of our hackathon project, that we made in 36 hours; but these projects that the seniors did--some in weeks, some in days-- were really kind of great.

They also gave me a pretty good shot-in-the-arm about all the project ideas I have. Yes, I have lots of ideas for apps, but one lesson I learned in creative writing: ideas are cheap. Now, after seeing all the things that people who are only 6 weeks more advanced can do, I feel like, sure, ideas are cheap and implementation is expensive, but I can pay the bills.

Or rather: the C8 demo was really both inspiring and impressive, in that I can't quite pay those bills yet, but I feel myself getting closer.

And I'm very excited for my friends and peers in C8, who inspired the title of this post.

Thursday, October 2, 2014

MakerSquare Day 26: Little nifty bits of magic (6/3)

You don't often hear "magic" and "database" in the same sentence, except for those sentences that start out, like this one, noting how rarely you hear "magic" and "database" in the same sentence, except for those sentences...

I can never resist a recursion joke.

So "database" and "magic" don't often go together, except for today, when I came back to ActiveRecord and saw how it had all these nifty bits of magic.

Seriously: I can't think of a better word than magic--or nifty--to describe ActiveRecord.

Up till now, a lot of the database work I've done has been directly in postgreSQL, which I weirdly liked. About a week ago, we looked briefly at how ActiveRecord serves as a mediator between SQL-like language and Ruby. It looked interesting and, sure, helpful, but I didn't want to give up the control I had of talking directly to my PSQL database; and anyway, I didn't have any project that needed a database right then.

Fast forward to today, when I was implementing a Rock-Paper-Scissors game and needed a database, and, what's that?, my old notes on ActiveRecord. "Well, why not?" I said to myself.

If you've seen 2001, you'll know what it's like after that, with all the colored lights and the brain-expanding monolith. To be clear: there's something slightly sinister about the Monolith in 2001 and there's something slightly sinister in letting ActiveRecord mediate for you. But still, there are all sorts of--I'll say it again--nifty bits of magic that go into ActiveRecord. Like telling tables so easily what they hold and then, automatically, the entities for those tables know what they should hold too. Or the ease of telling a table to make sure that it has a certain bit of info with "validates." Or--

And so on. You see that none of this is ground-shaking, Level 9 spellcasting. But it's all useful and neat and easy to use. Perfect for a Rock-Paper-Scissors game.

Now I'm off to update my database to show that I've beaten a million people at RPS, because that's one of the simple pleasures of having server access.

Wednesday, October 1, 2014

MakerSquare Day 25: Shiny happy programmers (6/2)

I'm not on the job market right now, but I'd be lying if I said I didn't occasionally think about what the job market is like for developers. Or what it will be like in six weeks, when I am on the market.

And the market is even more on my mind on those days when we talk to career services; or when established developers--MakerSquare grads, mentors, or just allies--come to talk to us about what it's like for them out there in the real world.

The real world is rather disappointing when compared to the computer world, in that the real world has far fewer arrays. I hope it's not too forward of me to say this, but: I love arrays.

But the real world is not so disappointing in terms of careers and places of employment. For instance, today a group of front-end developers at RetailMeNot came to speak to MakerSquare at lunch and they were--what's the word? Happy. They seemed like they liked their jobs and their co-workers, which is a real shock for me to see. (In grad school, where a large chunk of my adult life post-college was spent, people by-and-large are not happy. Or not at my grad school, at least.) 

On top of that shocking expose of what it was like to work in this field (they have foozball tables!), I also had a nice one-on-one chat with the head of MakerSquare career services, discussing possible places I would like to end up and possible salaries. It was a little on the abstract side--nothing as concrete as "I will work for foozball table time"--but it was a good start and something I hope will pay off when I do go on the market.

Which, ahem, will be in six weeks now. In case any possible employers are reading. And have a foozball table that isn't being used enough.

Note: Although we did a bunch of coding today, from brain-waking morning coding challenges to logging users in to a website, I've tagged this as "Teambuilding" to memorialize the time we spent at the end of the day working through a bunch of visual puns and jokes. As a team.