Big update with better conventions

Better conventions for boolean var names, function/method definitions with a space between the name opposed to invoking a function/method to distinguish the two. Use multiline var expressions instead of comma separated for vars with values. Included a section about a solid toType function.