Class: Bullseye::Tilt::BullseyeTemplate
- Inherits:
-
Tilt::Template
- Object
- Tilt::Template
- Bullseye::Tilt::BullseyeTemplate
show all
- Includes:
- FindParts
- Defined in:
- lib/bullseye/tilt/bullseye_template.rb
Constant Summary
Constants included
from FindParts
FindParts::SEPARATOR
Class Method Summary
collapse
Instance Method Summary
collapse
Methods included from FindParts
#actions, #controller, #parts
Class Method Details
.default_mime_type ⇒ Object
10
11
12
|
# File 'lib/bullseye/tilt/bullseye_template.rb', line 10
def self.default_mime_type
'application/javascript'
end
|
Instance Method Details
#evaluate(scope, locals, &block) ⇒ Object
17
18
19
20
21
22
23
24
25
|
# File 'lib/bullseye/tilt/bullseye_template.rb', line 17
def evaluate(scope, locals, &block)
@source = scope.logical_path.gsub(%r{^[^/]*/}, '')
<<-JS
Bullseye.target('#{controller}', #{actions.to_json}, function() {
#{data}
});
JS
end
|
#prepare ⇒ Object
14
15
|
# File 'lib/bullseye/tilt/bullseye_template.rb', line 14
def prepare
end
|