21 lines
No EOL
510 B
Ruby
21 lines
No EOL
510 B
Ruby
class Pages::GoMod < ::Phlex::HTML
|
|
def initialize(import, repo)
|
|
@import = import
|
|
@repo = repo
|
|
end
|
|
def view_template
|
|
render ::Pages::Layout.new({title: import}, meta: {
|
|
"go-import" => "#{import} git #{repo}"
|
|
}) {
|
|
p {
|
|
h1 { @import }
|
|
p {
|
|
plain "This is a generated page to host the Go module located at "
|
|
a(href: repo) { repo }
|
|
plain ". You'll probably find more information about it over there."
|
|
}
|
|
}
|
|
}
|
|
end
|
|
end
|
|
|