Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8635433
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T09:58:25+00:00 2026-06-12T09:58:25+00:00

I have a few non-standard assets (i.e. files that are not images/javascript files/stylesheets such

  • 0

I have a few non-standard assets (i.e. files that are not images/javascript files/stylesheets such as json and binary files) that live within a mountable engine (without isolate_namespace) in app/assets/data. I want these to be part of the asset pipeline (in the same way as e.g. images).
I can add them to the asset paths collection, e.g.

class Engine < ::Rails::Engine
  config.after_initialize do
    Rails.application.config.assets.paths << root.join("app", "assets", "data")
  end
end

and I can see in the Rails console that the assets are visible to the asset pipeline (e.g. via Rails.application.assets[] and ActionController::Base.helpers.asset_path). For instance, for a file app/assets/data/foo.json, the asset_path helper in the rails console for the hosting app gives me a path assets/foo.json, however that path does not work, I get a

ActionController::RoutingError (No route matches [GET] "/assets/foo.json")

error.

How can I get the hosting Rails app to serve these files?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T09:58:26+00:00Added an answer on June 12, 2026 at 9:58 am

    Turns out, this is some odd behavior with json files with specific names. The files in question are named something like schema-[UUID].json. Rails seems to think these are calls to some controller (even though there is no such route, nor a schema controller) that want json-formatted data back. When I rename the files to [UUID]-schema.json, they all of a sudden work.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a page that I want to update non stop, every few seconds.
I have a few generic classes that implement a common non-generic interface. I create
I have a few non-consecutive commits on the master branch that I'd like to
My web service hosted on Play! framework. I have few image files uploaded from
Hey guys, I am reading these so called non-blocking techniques, but i have few
I have standard WPF Window that I have extended the Aero Glass on the
I have a very large JSON string that I need to parse with in-browser
I have a few apps that I am trying to develop a reusable URL
I have few questions about ssis transction isolation levels. consider a scenario:I have an
i have few confusion regarding ORM(Object Relational Mapping) i am thinking about to use

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.