Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Add preview paths to view component

Oliver Günther8e5560dfd5f9
diff --git a/config/initializers/view_component.rb b/config/initializers/view_component.rb
new file mode 100644
index 00000000000..087ebd47e6e
--- /dev/null
+++ b/config/initializers/view_component.rb
@@ -0,0 +1,5 @@
+OpenProject::Application.configure do
+ config.view_component.generate.preview_path = Rails.root.join("spec/components/previews").to_s
+ config.view_component.preview_paths << Rails.root.join("spec/components/previews").to_s
+ config.view_component.generate.preview = true
+end