Sha256: 74e1df86f6c3d7ed1914dc67c710bab5b54d0fccf3a04e67f49a5daa5047f24c
Contents?: true
Size: 626 Bytes
Versions: 82
Compression:
Stored size: 626 Bytes
Contents
class Tutorial::Prerequisite attr_reader :name delegate :content, :yaml, :path, to: :@file_loader def initialize(current_step:, code_language:, name:) @current_step = current_step @code_language = code_language @name = name @file_loader = load_file! end def title @title ||= yaml['title'] end def description @description ||= yaml['description'] end def active? @name == @current_step end def load_file! Tutorial::FileLoader.new( root: Tutorial.task_content_path, code_language: nil, doc_name: @name, format: 'md' ) end end
Version data entries
82 entries across 82 versions & 1 rubygems