require "friendly_id"

module Dashboard
  class Engine < ::Rails::Engine
    isolate_namespace Dashboard

    config.generators do |g|
      g.test_framework :rspec
      g.fixture_replacement :factory_bot
      g.factory_bot dir: "spec/factories"
    end

    # Ensure engine's assets are precompiled
    initializer "dashboard.assets.precompile" do |app|
      app.config.assets.precompile += %w[dashboard.js sqm.css welcome.css]
    end
  end
end
