lib/easy_ml/engine.rb in easy_ml-0.2.0.pre.rc3 vs lib/easy_ml/engine.rb in easy_ml-0.2.0.pre.rc4
- old
+ new
@@ -7,15 +7,12 @@
require "numpy"
require "parallel"
require "polars-df"
require "pycall"
require "optuna"
-require "tailwindcss-rails"
require "wandb"
require "xgb"
-require "vite_ruby"
-require "vite_rails"
require "rails/engine"
require "activerecord-import"
require "historiographer"
module EasyML
@@ -80,18 +77,23 @@
app.config.generators do |g|
g.templates.unshift File.expand_path("../templates", __dir__)
end
end
- delegate :vite_ruby, to: :class
+ config.app_middleware.use(
+ Rack::Static,
+ urls: ["/easy_ml/assets"],
+ root: EasyML::Engine.root.join("public"),
+ )
+ # delegate :vite_ruby, to: :class
- def self.vite_ruby
- @vite_ruby ||= ViteRuby.new(root: EasyML::Engine.root)
- end
+ # def self.vite_ruby
+ # @vite_ruby ||= ViteRuby.new(root: EasyML::Engine.root)
+ # end
- config.app_middleware.use(Rack::Static,
- urls: ["/#{vite_ruby.config.public_output_dir}"],
- root: root.join(vite_ruby.config.public_dir))
+ # config.app_middleware.use(Rack::Static,
+ # urls: ["/#{vite_ruby.config.public_output_dir}"],
+ # root: root.join(vite_ruby.config.public_dir))
def list_routes
EasyML::Engine.routes.routes.map { |r| "#{r.name} #{r.path.spec}" }
end
end