mirror of
https://github.com/Neetpone/foalfetch.git
synced 2025-02-08 18:06:43 +01:00
11 lines
292 B
Ruby
11 lines
292 B
Ruby
# frozen_string_literal: true
|
|
require 'redcarpet'
|
|
|
|
class ChaptersController < ApplicationController
|
|
def show
|
|
@story = Story.find(params[:story_id])
|
|
@chapter = @story.chapters.find_by(number: params[:id])
|
|
|
|
@rendered_html = Ebook::EpubGenerator.render_chapter(@chapter)
|
|
end
|
|
end
|