Skip to content

Commit

Permalink
component: add .text helper
Browse files Browse the repository at this point in the history
  • Loading branch information
meh committed Feb 4, 2014
1 parent 9f90b96 commit 3242451
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions opal/lissio/component.rb
Expand Up @@ -127,6 +127,12 @@ def self.html(string = nil, &block)
end
end

def self.text(string)
render {
element.content = string
}
end

def self.css!(content = nil, &block)
if content || block
@global.remove if @global
Expand Down

0 comments on commit 3242451

Please sign in to comment.