-
Notifications
You must be signed in to change notification settings - Fork 4
/
dev.ru
34 lines (28 loc) · 612 Bytes
/
dev.ru
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
require 'bundler/setup'
Bundler.require
class ClearwaterDocsDev < Roda
assets = Roda::OpalAssets.new
route do |r|
assets.route r
r.on 'clearwater_hot_loader' do
r.run Clearwater::HotLoader
end
<<-HTML
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>Clearwater — A Ruby Front-end Framework</title>
#{assets.stylesheet 'default'}
<meta name="viewport" content="initial-scale=1,width=device-width" />
</head>
<body>
#{assets.js 'dev'}
</body>
</html>
HTML
end
end
Clearwater::HotLoader.start
use Rack::Deflater
run ClearwaterDocsDev