2b4d245f by Contra Committed by Michael Richards

Add support for top-level keypaths.

1 parent 1c10de2b
......@@ -150,8 +150,12 @@ class Rivets.View
path = context.shift()
splitPath = path.split /\.|:/
options.formatters = pipes
model = @models[splitPath.shift()]
options.bypass = path.indexOf(':') != -1
if splitPath[0]
model = @models[splitPath.shift()]
else
model = @models
splitPath.shift()
keypath = splitPath.join '.'
if model
......