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 7558397
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T12:21:45+00:00 2026-05-30T12:21:45+00:00

A typical extjs example application includes the extjs library by referencing files such as:

  • 0

A typical extjs example application includes the extjs library by referencing files such as:

ext-all.css
ext-all.js

What’s the ‘rails 3.1 way’ of including these files, noting that they reference hundreds? of files in subdirectories

(e.g. ext-4.0.2/resources/themes/stylesheets/ext4/default/_all.scss)

and there are relative paths:

(e.g. background-image:url(‘../../resources/themes/images/default/shared/shadow.png’))

I’m tried numerous combinations of require_tree et al., but can’t seem to get it to work.

I’m wondering if I need to mess w/ ‘provide’, but I can’t seem to find the documentation I need.

  • 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-05-30T12:21:46+00:00Added an answer on May 30, 2026 at 12:21 pm

    What you want is for this file to compile via the Rails asset pipeline:

    resources/themes/templates/resources/sass/my-ext-theme.scss
    

    To get this to work, I learned a few things the hard way:

    1. ExtJS uses SASS to compile (so does Rails) and Compass, which includes blueprint and compass CSS kits. Compass doesn’t work with rails, you need to use the gem “compass-rails”, which doesn’t include the CSS toolkits. Only the main compass gem has these toolkits, and it’s a dependency for compass-rails so you should get them if you bundle compass-rails, they need to be in your sass.load_paths config. If you include the “compass” gem without compass-rails you will have strange errors and become an expert at the rails asset pipeline as you try to solve them!
    2. ExtJS uses an older version of SASS, the newer one Rails uses doesn’t like having functions and mixins defined inside of modules. To fix this, look at the errors it’s giving you (always a function or mixin definition) and move them to _functions or _mixins files.
      (more info: getting error after ugrading to sass-3.1.8)

    Here’s how to get up and running:

    Put this into your config/application.rb:

    # Set up our ExtJS SASS build environment
    config.sass.load_paths << "#{Rails.root}/vendor/assets/stylesheets"
    config.sass.load_paths << "#{Rails.root}/vendor/assets/frameworks/compass/stylesheets"
    config.sass.load_paths << "#{Rails.root}/vendor/assets/frameworks/blueprint/stylesheets"
    

    Put the ExtJS stylesheets (the ext4/default directory in the SDK) here:

    vendor/assets/stylesheets/ext4/default/
    

    Put my-ext-theme.scss into app/assets/stylesheets and use it like you normally would with rails. It will call this code:

    @import 'ext4/default/all';
    

    That will bring in all of the ExtJS definitions, and you should be on your way.

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

Sidebar

Related Questions

A typical way to use JFileChooser includes checking whether user clicked OK, like in
Typical way of creating a CSV string (pseudocode): Create a CSV container object (like
The typical way of selecting data is: select * from my_table But what if
For a typical business application, should the focus be on client processing via AJAX
During a typical day programming, I implement functions in a way that I would
The typical documentation on locking in innodb is way too confusing. I think it
In a typical organization application i create, entities User , Projects , Company ,
Although the example below exploits ExtJS, one can easily extrapolate to another framework. I
Typical scenario: SomeModule.find(:all, :conditions [xyz = ?, some_var] SomeModule.find(:first, :conditions [xyz = ?, some_var]
The typical way to use : <?php class A { public $var; public function

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.