# Edit red.js file

**URL:** <https://discourse.nodered.org/t/edit-red-js-file/78846>\
**Category:** General\
**Created:** [31 May 2023 17:02 UTC](https://discourse.nodered.org/t/edit-red-js-file/78846 "2023-05-31T17:02:17Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jhonnsec](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/jhonnsec/32/80251_2.png) [@jhonnsec](https://discourse.nodered.org/u/jhonnsec)\
**Post date:** [31 May 2023 17:02 UTC](https://discourse.nodered.org/t/edit-red-js-file/78846/1 "2023-05-31T17:02:17Z")

</div>

hello my friends I'm editing a function file red.js button deploy I saw that it has this function but when doing the build it returns to the original state someone has already made this modification.

packages/node\_modules/@node-red/editor-client/public/red/red.js

I'm editing the same in this place, but when I build it, it comes back to the original file.

/\*\*  
\* options:  
\* type: "default" - Button with drop-down options - no further customisation available  
\* type: "simple" - Button without dropdown. Customisations:  
\* label: the text to display - default: "Deploy"  
\* icon : the icon to use. Null removes the icon. default: "red/images/deploy-full-o.svg"  
\*/  
function init(options) {  
options = options || {};  
var type = options.type || "default";

---

<div class="post-metadata">

**Author:** ![ralphwetzel](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/ralphwetzel/32/53713_2.png) [@ralphwetzel](https://discourse.nodered.org/u/ralphwetzel)\
**Post date:** [31 May 2023 19:41 UTC](https://discourse.nodered.org/t/edit-red-js-file/78846/2 "2023-05-31T19:41:54Z")

</div>

Hi @jhonnsec  
Welcome to this forum!

`packages/node_modules/@node-red/editor-client/public/red/red.js` **is** the file created when building the Node-RED system. Thus it's the wrong place to do any modifications.

The source of the snipplet you're looking for is located in `packages/node_modules/@node-red/editor-client/src/js/ui/deploy.js`. If you modify this file, your changes will end up in `.../red/red.js`.
