# Extracting engine parts from public/

**URL:** <https://www.ruby-forum.com/t/extracting-engine-parts-from-public/96810>\
**Category:** Engines\
**Created:** [July 2, 2006, 7:28am UTC](https://www.ruby-forum.com/t/extracting-engine-parts-from-public/96810 "2006-07-02T07:28:32Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dracos](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/ea666f/32.png) [@dracos](https://www.ruby-forum.com/u/dracos)\
**Post date:** [July 2, 2006, 7:28am UTC](https://www.ruby-forum.com/t/extracting-engine-parts-from-public/96810/1 "2006-07-02T07:28:32Z")

</div>

Hi,

I am happily extracting an engine from my Rails app. Every thing has  
gone smoothly so far but now I’m trying to extract the required  
JavaScript, CSS and image files. This doesn’t seem to work the way I  
expected. Where do I put these files in the engine?

I hope will similarly named javascript in my main rails app will  
shadow a javascript file in my engine.

Thanks,  
Peter

---

<div class="post-metadata">

**Author:** ![dracos](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/ea666f/32.png) [@dracos](https://www.ruby-forum.com/u/dracos)\
**Post date:** [July 2, 2006, 8:10am UTC](https://www.ruby-forum.com/t/extracting-engine-parts-from-public/96810/2 "2006-07-02T08:10:47Z")

</div>

On 7/1/06, Peter M. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Hi,
> 
> I am happily extracting an engine from my Rails app. Every thing has  
> gone smoothly so far but now I’m trying to extract the required  
> JavaScript, CSS and image files. This doesn’t seem to work the way I  
> expected. Where do I put these files in the engine?

No problem with engine\_image and engine\_stylesheet:)

Thanks,  
Peter

---

<div class="post-metadata">

**Author:** ![dracos](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/ea666f/32.png) [@dracos](https://www.ruby-forum.com/u/dracos)\
**Post date:** [July 2, 2006, 3:09pm UTC](https://www.ruby-forum.com/t/extracting-engine-parts-from-public/96810/3 "2006-07-02T15:09:33Z")

</div>

How do you expect it to work? What have you tried, and what  
(unexpected) behaviour has it produced?

---

<div class="post-metadata">

**Author:** ![dracos](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/ea666f/32.png) [@dracos](https://www.ruby-forum.com/u/dracos)\
**Post date:** [July 2, 2006, 3:58pm UTC](https://www.ruby-forum.com/t/extracting-engine-parts-from-public/96810/4 "2006-07-02T15:58:46Z")

</div>

On 7/2/06, James A. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> How do you expect it to work? What have you tried, and what  
> (unexpected) behaviour has it produced?

Hi James,

I remembered seeing engine\_image and engine\_stylesheet and these  
methods solved all my problems.

I’ve known I’ve needed engines for a long time and only had time to  
sit down and make my first extraction yesterday. Engines are really  
great! Thank you!

Peter
