Tuesday, March 5, 2013

Kul proof of concept

So my web app framework proof of concept is up and working. The github repo has the code I'm working with at the moment. It's basically a science project at the moment just to see if it makes sense.

Which I think it does. Currently it has a server / app / controller folder structure, dynamically reloads the code for those objects, and renders an HTML erb for the path given (in context of the controller if it exists). And that's the thing I love about Ruby - so little code and it's already working.


There's still a lot to do before I really am prepared to release it as a gem:


  • I'd like to see if rendering html pages at the server and app level is useful. I could provide them an app and controller context and go from there.
  • The controller should have access to the app and controller context.
  • There's a base controller but no base app or server. I think the base server should be the main class like it is in Sinatra.
  • Routing helpers. I like these in Rails, even though they're only slightly less fragile then actual hard-coded string routes would be. Unfortunately one of my design goals was to get rid of the routing file, which is where Rails builds its routes from. I've got a couple of ideas, but nothing that seems amazing.
  • Better code reloading. Right now I'm just reloading the code files, which is not optimal. I remember seeing a gem that does this, I think.
  • Bundle up into a gem - never done that before, should be interesting. 
And if I get all of that finished, I'm thinking about a very light framework to deal with SQLlite databases. In Ruby it should be pretty straightforward to push / pull models in and out of the database. I probably will want to decouple this from the actual Kul framework - there's no reason to have them tightly coupled. I'd like to have the framework able to use whatever database layer that the user wants - that's simple to do in Rails and I'd like to maintain that ease of use.

Also need to put some thought into how I'm going to deploy this. Step one is researching how Sinatra gets deployed, since it's basically a Sinatra app.

No comments:

Post a Comment