Tuesday, April 30, 2013

Performance test and debugging for Noobs - Rails, Heroku and Rails

Monday I stopped by the New Relic office for live streaming #RailsConf. Creator #DHH talked about the future of Rails - Rails 4 and multiple caching options, designing pattern details. I saw New Relic last time when they brought the Obama tech team to SF. Not impressed, but today I hit a Heroku bug and was tired of tailing the logs (having to constantly go back to my machine) and Pg Admin to shared Amazon servers... yeah too much overhead for my one-pager. What do I do? Also, what's a better opportunity to learn a tool without having to read the documentations? We all know documentations are important in coding.

For Rails app hosted on Heroku


Deploy to Heroku and select New Relic as an Add-on


Command line $heroku addons:add newrelic in the Rails app directory of your newly deployed app

You may be prompted for

That means you have to enter your credit card, no worries, you won't be charged. But you may want to reset your Heroku password to something more secure.

Run $heroku addons:add newrelic again after "verification"


Feel free to run $heroku addons:docs newrelic to open up the documentation
Or visit

Follow documentation to add gem to gemfile (gem 'newrelic_rpm') then bundle install

In Rails app directory:

$curl > config/newrelic.yml

Modify your newrelic.yml file that you just received in the config directory of your Rails app. Change your app name

app_name:"your app name here"
or use the environment variable format provided

Go to your app refresh a few times, navigate through a few pages and generate some traffic

Log back into Heroku, navigate to your app admin, then the Add-on, select new relic, you will be automatically log into your Dashboard

You just gained access to your full performance and error log for both front end and back end. I was able to get data on page rendering, DOM load, script and database performance. It was awesome. For those who don't like $heroku logs --tail, or simply aren't on the right computer all the time with the right toolbelt. Here's an awesome way to view your stats.

While the stats is a bit of overkill compared to Google Analytics for an average user, but the error log (narrowing down to controller, methods, and specific ruby stack trace) was invaluable even for a noob.

A common noob mistake that I and many people make: forgetting to update the repo, so you will need to
$git add . (or add whatever)
$git commit -m"e.g. adding the newrelic.yml file"
$git push
$git push heroku master

Wednesday, April 24, 2013

Portfolio for inspirational training

Hi Magali, Thank you for viewing our portfolio page made especially for you.
Have a great day! Cheers,
Eva, Tamara and Dilys

We encourage our vision lead to start with wireframing, a creative designing process that creates a medium of discussion among the idea leader, designers and developers. This creates a designer prototype that will inspire discussions, rapid prototyping and result in final products that embodies the original visions. You can use wireframing software, draw, whiteboard, any fun colorful and interactive process that you like!



Pure neutral CSS

Modern minimalism layout

Pinterest-like layout

Unusual Colors

Mobile themes

Sample live websites:
Mexican Travel Website
Pure CSS Design Website, interactive forms
Form generator site

Tuesday, April 23, 2013

Bootcamps and Words of Caution

I read these two great posts on a blog owned by a Dev Bootcamp graduate, and a successful professional developer. They are great words of caution for candidates of bootcamps:

The Economics of Dev Bootcamp (And Other Hacker Schools)

You Could Be Kicked Out Of Dev Bootcamp

And I replied to the posts with my own observations:
I have always been a little suspicious of their stats. I agree with you that a word of caution is needed. I am also attending a bootcamp now. Unlike traditional schooling it is faster, cheaper, more effective in the real engineering world, but for sure, it's no amazing education pill. Many who have different learning styles feel the burn. As peers, we are trying really hard to look out for one each other, and fill in the gap. Hope all candidates exert caution. 

It is also good to point out that some schools like App Academy does it preemptively , e.g. they quiz you and test out your programming capability before hand as a part of the application process.

I am running long here, Natasha's post are really enjoyable and thought-provoking. She's so right that *lots of preparation is needed* before joining a bootcamp. And also during the bootcamp, keep in mind that some already went through other forms of advanced training and will often say *that(programming) is easy*. Please don't get discouraged. It depends so much on the individual students. The best students in the current class have surprised our peers. They come from all walks of life.

Wednesday, April 17, 2013

And you wonder why Javascript is important!

It is easy to get distracted these days with Ruby on Rails, Django... fancy frameworks, pop DB noSQL. The fundamentals often get ignored and pushed to the back burner. We start to forget Javascript is still the omnipresent front end language, and in many cases, it is more than that - think Backbone, Node... Yes, it is truly everywhere. It might be an oldie like C and Java, but none of the trio is going anywhere.

That pushes me back to the not so distant memory of Codecademy, which started as all Javascript. Is it important? Yes, it was a conscious choice (according to at least one interview count). Js is the language of the web hence, Codecademy decided to use that for its beginner tutorials.

Need more convincing, fast? Indeed: it helps to know Javascript to use jQuery, front end interactive web design, AJAX displaying new info without refreshing a page, APIs, tons of web APIs spit out json and use js, and of course just the fundamentals : grammar. Javascript is particular, it is good to start with a particular, picky language and move on to less restrained ones later (it's feels like a relief!), and it makes you pay great attention to syntax. Detail-oriented helps save debugging time.

Tuesday, April 16, 2013

Q&A Choosing Web Development Bootcamp [VIDEO]

LoroCard is now open source!

Getting started on Front End design or development?
Check out my Project LoroCard. Its code is now fully on GitHub. Feel free to use it to practice GitHub as well: git clone your own copy, pulling, reporting issues and submitting questions.

This project is pure front-end. You can pull the entire source code!

:) enjoy

Tuesday, April 9, 2013

A Happy Dosage of Sheryl Sandberg for Aspiring Girl Coders and Businesswomen

Lean In the book by Sheryl Sandberg

Her life isn't all privileged. She had to fight, adapt and learn, and stand up again too.

"chapters after chapters of advice and studies" - CNN

Levo League live office hour with Sheryl Sandberg

Also a great resource for aspiring ladies

Sheryl Sandberg explains Lean In briefly on CNN

Too busy to read, or thinking Sheryl's too lofty to everyday women?

Sheryl Sandberg at my college back in the days - Stanford

Relentlessly Pleasant and other studies, tips about how to be a successful woman

Bizarre Jokes and Memes that go along with coding? Finding Nemo is one.

The Struggle of Struggles - A Confession of A Noob

Coding Dojo - our bootcamp has an annoying motto : struggle to learn. It is hard to agree to, because in turn, we suffer through struggling. But it is hard not to concur, because we learn so much in that struggle.

Half a year ago, Ruby on Rails seems to be magical. rails g, rake db:migrate, git push, git push heroku... voila your app is ready! And it is awesome, it looks like Twitter without the tags, and everything works! Feel free to view post edit delete... wow congrats you just said the fanciest Hello World with a full blown web app. Who cares about Michael Hartl's tutorial? This thing just works. I am now a RoR developer, except... NOT.

The moment to customize and build on top of the app began... all of a sudden, motion freezes: the magic turns into suffering. What happened? What do I do? What the heck is MVC, rspec, css.css, html.erb, rake here rake there... okay, i hate ruby and as well as Rails now, because they are so zen that my head hurts.

Our "sensei" made us suffer HTML CSS jQuery Ajax PHP all the fundamentals, Object Oriented Programming OOP, CodeIgniter, Object Relational Mapping ORM... basically lots lots of tedious suffering later: finally Ruby... okay finally one week later Rails. After building three full blown Heroku deployed Rails app and unfinished console game, and lots of Rails talk later. I am really really starting to understand Rails on a deep level. It's hard to describe but you just know.

I am still going slowly, very slowly, and I want to see all the knots and bolts of Rails, why was it designed that way, why Ruby, why does everyone like Ruby... and that's when I realized how deep Rails can really go. And there I was beaming while writing StaticPages controller. Yes, WTF? So many apps later, I am beaming on some freaking StaticPages controller? oh yes, love it, love that I understand the rspec, the console command lines, the history of vi and vim... and yes I wrote some instance variables too to be passed to views... but gosh it feels so good to really understand how instructional it is to generate a static page backwards using Rspec Green Red Refactor method and know that I can just add my variables any time.

Finally, I am *starting* to understand Rails - a confession of a beginner.

Sunday, April 7, 2013

Lean In Chapter 1 admitting the ambition

Chapter by Chapter Reaction to

Sheryl Sandberg's Lean In

Posting a blog post about reading Sheryl's Lean In is actually ... admitting that I want to be an ambitious, successful, boardroom squatting woman! Gasp, us women simply don't do that. Sheryl's is saying we actually have to fight for better rights, the progress has simply stalled.

Standing on the shoulder of giants?

My high school classmate Lucy has led the feminist club, rallied ladies and guys to vocalize the demand for equality. I heard great names like Virginia Woolf, but I had no idea what she was about? Something about anonymous female authors, something about universal suffragettes .. all the concepts and people blend together. Okay, I fail as a feminist, and I never thought myself as one. Because being a feminist is saying more than demand equality. It is actually more extreme, it demands more in light of all the unfairness that women have suffered. To defend the victims, we almost have to over compensate and say that women are better. But of course, all concepts need to be more mellow and friendly, as well as accepting to have mass appeal, and may be then, the concept of women being better and being leaders have mellowed down...

Sheryl Sandberg is saying fighting is needed though. And that is true feminism. If we don't fight for better lives for women, better compensation, leadership opportunities, the progress will be stalled further, and all who is not doing that, is just enjoying a free ride - riding on the shoulder of giants trying to reach the sky. 

The sky does not just come down and meet up. 

Sigh and thrill, I just realized that the time is different. This is the exciting times of being a woman, being a woman in the tech world, being a woman learning how to code. Oh gosh, what shall I do? I can tell something exciting is happening, like Katy Perry's Firework song makes crackles, makes you want to jump, shine and then burst. 

Love it, as I dig deeper in technology, I have discovered a great read - the modern feminist manifesto by a business lady. She might cause controversial because her background is unusual, privileged, and powerful, but hey, I am so glad that she got me thinking, ticking, and now becoming unrested.

 --- Below is a video by Levo League, Caroline Ghosn is a co-founder, and she is a Stanford alumna <3 flowers for her.  ---

The Big Move

The new class at Coding Dojo is starting tomorrow on Monday. The current class has about 3 weeks overlap, and we are moving downstairs leaving the upstair, brighter and better office space for the new class. I don't think I like the chemical smell of new furniture very much, but I haven't made up my mind about this overlap.

Will we get enough attention, help, support? How is the staff time going to be divided between the classes? It certain is doable and somewhat reasonable to have this overlap, but definitely some unease too. 

I did sign up for some TA sessions, to help the new class with topics that are very interesting to me PHP MySQL. I actually would like to help with other parts too but it is too close to demo day. HTML, CSS, jQuery are areas of interest to me too. 

So much of learning how to code in a bootcamp is not about the coding. It is really about all the parts that come along as a package. It is about the commute, dividing time among family & friends, learning, dealing with life... it's never just about coding. That is why this is a big commitment, and sort of a life adventure / milestone. We will see how things turn out. 

React UI, UI UX, Reactstrap React Bootstrap

React UI MATERIAL  Install yarn add @material-ui/icons Reactstrap FORMS. Controlled Forms. Uncontrolled Forms.  Columns, grid