# File Change Not Picked Up

**URL:** <https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004>\
**Category:** Elements\
**Created:** [March 30, 2025, 10:50pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004 "2025-03-30T22:50:10Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bill](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/bill/32/107_2.png) [@Bill](https://forums.realmacsoftware.com/u/Bill)\
**Post date:** [March 30, 2025, 10:50pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/1 "2025-03-30T22:50:10Z")

</div>

Hi @tpbradley

I have a script call in Body End that points to a js file in Resources and I noticed that any changes in that file are not being automatically picked up when previewing.

The only workaround right now is to remove the file and then put the file back, which is quite tedious.

---

<div class="post-metadata">

**Author:** ![tpbradley](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/tpbradley/32/25503_2.png) [@tpbradley](https://forums.realmacsoftware.com/u/tpbradley)\
**Post date:** [April 11, 2025, 7:07pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/2 "2025-04-11T19:07:31Z")

</div>

Sorry, somehow missed your message. How are you updating the script in Resources?

---

<div class="post-metadata">

**Author:** ![Bill](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/bill/32/107_2.png) [@Bill](https://forums.realmacsoftware.com/u/Bill)\
**Post date:** [April 11, 2025, 7:24pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/3 "2025-04-11T19:24:42Z")

</div>

I’m updating in a text editor and saving changes. Would be nice if nothing was cached and would instantly pick up any changes made to the file (at least when previewing).

---

<div class="post-metadata">

**Author:** ![tpbradley](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/tpbradley/32/25503_2.png) [@tpbradley](https://forums.realmacsoftware.com/u/tpbradley)\
**Post date:** [April 11, 2025, 7:27pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/4 "2025-04-11T19:27:08Z")

</div>

Are you cracking open the document bundle and editing it from there?

---

<div class="post-metadata">

**Author:** ![Bill](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/bill/32/107_2.png) [@Bill](https://forums.realmacsoftware.com/u/Bill)\
**Post date:** [April 11, 2025, 7:28pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/5 "2025-04-11T19:28:56Z")

</div>

No I’m not messing with the Elements bundle, I have a js file in resources and I’m editing it like a normal person by selecting it in the finder and editing it - lol

---

<div class="post-metadata">

**Author:** ![tpbradley](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/tpbradley/32/25503_2.png) [@tpbradley](https://forums.realmacsoftware.com/u/tpbradley)\
**Post date:** [April 11, 2025, 7:31pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/6 "2025-04-11T19:31:37Z")

</div>

I think I’m overthinking it LOL. Do you edit an external copy of the file in a text editor, then remove the existing script from resources in the Elements app, and drag the new edited version in?

---

<div class="post-metadata">

**Author:** ![dan](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/dan/32/28516_2.png) [@dan](https://forums.realmacsoftware.com/u/dan)\
**Post date:** [April 11, 2025, 7:45pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/7 "2025-04-11T19:45:57Z")

</div>

> [@Bill](#):
>
> I have a js file in resources and I’m editing it like a normal person by selecting it in the finder and editing it - lol

Any files added to the Resources area are stored in the Project and do not reference your original files on disk, so you can’t just edit them in the Finder.

 ![CleanShot 2025-04-11 at 8 .42.21@2x](https://europe1.discourse-cdn.com/flex005/uploads/realmacsoftware1/original/3X/c/0/c096f54e4b8f52447b167976fc621795be488692.jpeg)

You could use the new Code page feature if you want an editable JS file in your project.

 ![CleanShot 2025-04-11 at 8 .44.45@2x](https://europe1.discourse-cdn.com/flex005/uploads/realmacsoftware1/original/3X/8/b/8bb4dbbce15e53880ae778bcfdf12d80916c9ee2.jpeg)

Does that help?

---

<div class="post-metadata">

**Author:** ![Bill](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/bill/32/107_2.png) [@Bill](https://forums.realmacsoftware.com/u/Bill)\
**Post date:** [April 11, 2025, 8:05pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/8 "2025-04-11T20:05:45Z")

</div>

Yes, that’s what I’m doing currently.

---

<div class="post-metadata">

**Author:** ![tpbradley](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/tpbradley/32/25503_2.png) [@tpbradley](https://forums.realmacsoftware.com/u/tpbradley)\
**Post date:** [April 11, 2025, 8:12pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/9 "2025-04-11T20:12:11Z")

</div>

Yeah, using the new Code page as @dan suggested is the way I’d go for this. You could create a `scripts` folder at the root of the site and add a code page in there for your script.

---

<div class="post-metadata">

**Author:** ![Bill](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/bill/32/107_2.png) [@Bill](https://forums.realmacsoftware.com/u/Bill)\
**Post date:** [April 11, 2025, 8:13pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/10 "2025-04-11T20:13:58Z")

</div>

I’m not sure if code page will work, but it crashed when I tried to setup one - just sent in a crash report. Is that code page easily extractable when I move to dev packs?

---

<div class="post-metadata">

**Author:** ![tpbradley](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/tpbradley/32/25503_2.png) [@tpbradley](https://forums.realmacsoftware.com/u/tpbradley)\
**Post date:** [April 11, 2025, 8:24pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/11 "2025-04-11T20:24:57Z")

</div>

Ah yes, I’m pretty sure this crash only happens on macOS 13 - I’ll get that fixed up. I don’t think you’ll be able to create a code page until then.

To extract the code you’d just have to select the page in the project outline, then copy the content.

---

<div class="post-metadata">

**Author:** ![tpbradley](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/tpbradley/32/25503_2.png) [@tpbradley](https://forums.realmacsoftware.com/u/tpbradley)\
**Post date:** [April 12, 2025, 10:51am UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/12 "2025-04-12T10:51:24Z")

</div>

@Bill We’ve just released an update that should fix the crash, can you give code pages a try and let us know if this works for you.

---

<div class="post-metadata">

**Author:** ![Bill](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/bill/32/107_2.png) [@Bill](https://forums.realmacsoftware.com/u/Bill)\
**Post date:** [April 12, 2025, 4:11pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/13 "2025-04-12T16:11:10Z")

</div>

Thanks @tpbradley Adding a file in pages panel now works. You didn’t have to do this on the weekend, but it is appreciated.

Quick question, if I wanted to use that file temporarily , is there a path variable to a page file like this to use in the ‘Edit Extra Code’ locations ?

---

<div class="post-metadata">

**Author:** ![dan](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/dan/32/28516_2.png) [@dan](https://forums.realmacsoftware.com/u/dan)\
**Post date:** [April 12, 2025, 4:20pm UTC](https://forums.realmacsoftware.com/t/file-change-not-picked-up/47004/14 "2025-04-12T16:20:35Z")

</div>

> [@Bill](#):
>
> Quick question, if I wanted to use that file temporarily , is there a path variable to a page file like this to use in the ‘Edit Extra Code’ locations ?

I don’t think you need a path variable, becuase you set the location of the page.

`/code/yourfile.js`

And here’s a working example…

 ![CleanShot 2025-04-12 at 5 .19.39@2x](https://europe1.discourse-cdn.com/flex005/uploads/realmacsoftware1/original/3X/e/3/e3679df136e4e97295006a77814a2d8bca1bb7b6.jpeg)

Hope that helps.
