lib/lookbook/config.rb in lookbook-1.0.4 vs lib/lookbook/config.rb in lookbook-1.0.5

- old
+ new

@@ -3,11 +3,11 @@ require "lookbook/store" module Lookbook class Config def initialize - @options = Store.new + @options = Store.new({}, true) @options.set({ project_name: "Lookbook", log_level: 2, auto_refresh: true, @@ -29,14 +29,13 @@ listen: Rails.env.development?, listen_paths: [], listen_extensions: ["rb", "html.*"], listen_use_polling: false, - cable_mount_path: "/lookbook-cable", + cable_mount_path: "/cable", cable_logger: Lookbook.logger, - runtime_parsing: !Rails.env.production?, parser_registry_path: "tmp/storage/.yardoc", ui_theme: "indigo", ui_theme_overrides: {}, ui_favicon: true, @@ -102,10 +101,14 @@ } } }) end + def runtime_parsing=(value) + Lookbook.logger.warn "The `runtime_parsing` config option has been deprecated and will be removed in v2.0" + end + def project_name @options.project_name == false ? nil : @options.project_name end def components_path @@ -243,10 +246,10 @@ def normalize_paths(paths) paths.map! do |path| full_path = absolute_path(path) full_path if Dir.exist?(full_path) end.compact! - paths + paths.uniq end def absolute_path(path) File.absolute_path(path.to_s, Rails.root) end