Developer Detour: Trailing Semicolons FTW
Our Dev Team works HARD at Seelio, and we love them for it.
KIDDING, but they do have little time to write blog posts, so we were real thrilled when our head developer David sent us this.
Those who want to know what its like to be a Seelio developer, enjoy!
Today after we compiled and launched our new add work feature (check it out, btw! Screengrabs, image grabs, and Vimeo integration are all new!), my coworker turned her laptop around to show me our page jumbled all together and beyond recognition. As every programmer knows, one semicolon can make a disproportionate amount of difference.
Object is not a function.
Copy the new script to the server as a file. Pasting that many characters and lines proved prohibitive over ssh and vim. Find the offending line.
Google the issue. This is always a step.
Add a semicolon in the offending line at the appropriate spot. Everything works.
Add a trailing semicolon to the former of the two concatenated files, so that, when concatenated, there will be a semicolon between the two.
Push the changes to the live server. Crisis averted.
1) If you’re going to concatenate scripts, run your pages once with everything concatenated to make sure everything checks out.
2) Also, add trailing semicolons to all your files. It will make concatenating just a little safer.