LitePost on CFWheels – Done!!

It seems like it’s been forever since I started working to create my own CFWheels version of the LitePost blog application. Work and life interrupted me along the way, but I managed to finish what I’ll call a first version. Ironically, the hardest part seems to have been trying to get it into some sort of version control and accessible for others. Figured that out, I think, and it is now available on GitHub. I will share some highlights and thoughts of the project.

LitePost using CFWheels

Worry about functionality first. The design can be worked out later.

Early on, I decided to work with text only. However, I found myself thinking, “This doesn’t look like a blog.” I then interrupted coding the blog to integrate a layout. I then went back to coding the application. What I found was that I began to get more consumed with the output and how it looked rather than the fact that it worked. I found I was programming for shorter durations of time.

Eventually, I actually took a step back and got rid of the layout altogether so I could just focus on the code. I found that I would work longer and with less distraction since I had no design elements to worry about.

Know when to use the scaffold plugin

Immediately upon getting the database created, I set about running the Scaffold plugin for each table. The Scaffold plugin, which is a wonderful bit of code by Raul Riera, creates the model, view, and controller with CRUD functions for whatever db table you point it to. I thought this would be a quick way to get up and running so I could concentrate on the more complex code. It certainly got the application running very quickly, but I found that a lot of the generated code got in my way or caused distractions for me. This is not any kind of judgement of the plugin itself. Honestly it could just be me. Again, I took a step backward and began to code my models, views, and controllers from scratch by hand. Ironically, this step backward actually resulted in my pace picking up.

What’s next?

I have to admit I feel a tremendous sense of accomplishment at finishing any project and this one was no different even though it is simply a personal project that likely no one will use. I learned a lot about CFWheels during the course of building LitePost. I intend to tweak it with additional features and improvements. My hope is that by making the code public, others in the CFWheels community, the ColdFusion community, or both will take a look and offer up constructive criticism. I feel this is how I can learn to be a better programmer.

At the top of my list of things I’d like to do is add a rich text editor instead of the plain old textareas that are currently in use. I’d also like to come up with a better RSS feed. Currently the feed is done using the <cffeed> code straight from the CFWACK. The query is hard coded with no paramaters and the XML is generated at the end all on the same page. I’d like to do it using a controller and possibly a custom layout that is XML rather than HTML/CFML.