# Project in Node-red for Code Nodes. Store code in files

**URL:** https://discourse.nodered.org/t/project-in-node-red-for-code-nodes-store-code-in-files/100765
**Category:** General
**Created:** [14 April 2026 09:26 UTC](https://discourse.nodered.org/t/project-in-node-red-for-code-nodes-store-code-in-files/100765 "2026-04-14T09:26:20Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![stoivo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/stoivo/32/106669_2.png) [@stoivo](https://discourse.nodered.org/u/stoivo)
#### Post date: [14 April 2026 09:26 UTC](https://discourse.nodered.org/t/project-in-node-red-for-code-nodes-store-code-in-files/100765/1 "2026-04-14T09:26:20Z")

</div>

We have a project in Node-red. We have some code nodes with a 10-30 lines of code and some nodes with hundreds of lines. Some of the nodes are hooked together so like requesting data from the database, calculating, etc.

I played a bit with NodeRed project. I was surplices that content of the code nodes are stored in the flow.json. I think it would have been very node to have a folder called `code_nodes/<id>.js` so it would be easier to modify the code directly. Maybe I could test this flows in some capacity too.

Maybe this exists, I just been looking the wrong direction? I could also use custom nodes but I would have liked the code to be somehow readable from the GUI as my boss would like to be able to change it without too much of a build process.

Any suggestion

---

<div class="post-metadata">

### Author: ![Aaqu](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/aaqu/32/101407_2.png) [@Aaqu](https://discourse.nodered.org/u/Aaqu)
#### Post date: [14 April 2026 12:54 UTC](https://discourse.nodered.org/t/project-in-node-red-for-code-nodes-store-code-in-files/100765/2 "2026-04-14T12:54:09Z")

</div>

Is this supposed to be in the Node-Red editor? Theoretically, you could build a VS Code plugin that works with the flow.json file (maybe such a solution already exists).

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/5/7/57752b4014a5d2ad02d4568c3a2853052b6b7955.png)

---

<div class="post-metadata">

### Author: ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)
#### Post date: [14 April 2026 19:07 UTC](https://discourse.nodered.org/t/project-in-node-red-for-code-nodes-store-code-in-files/100765/3 "2026-04-14T19:07:43Z")

</div>

The purpose of the function node is to provide flexibility and easy access to code where needed. It wraps the code in a Node.js VM to isolate it.

Someone did create an alternate node that allows code to be loaded from files - not sure if it is being maintained.

Of course, you also have several other options.

You can use settings.js to import code which can then be accessed via global context.

In addition, as @Aaqu has said, you can create plugins that make functions available. I've moved various common functions into Editor and Runtime plugins in UIBUILDER.

---

<div class="post-metadata">

### Author: ![stoivo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/stoivo/32/106669_2.png) [@stoivo](https://discourse.nodered.org/u/stoivo)
#### Post date: [15 April 2026 14:45 UTC](https://discourse.nodered.org/t/project-in-node-red-for-code-nodes-store-code-in-files/100765/4 "2026-04-15T14:45:25Z")

</div>

I don't want to use node red editor. I want to use one locally like Zed.

How did you create the screenshot? Which tool is this

I did a bit more looking around and figured I could use the flow.json and create tool myself to extract the data.

I found a tool now which does this

> **[GitHub - daniel-payne/functions-templates-manager: integrate vs-code with node-red](https://github.com/daniel-payne/functions-templates-manager)**
>
> integrate vs-code with node-red

**A demo video**

[![](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/b/8b994b8bbf8fc2f2419be735a82403888c537348.jpeg "Node-red and VS-code Integration") ](https://www.youtube.com/watch?v=UivEETkSWW8)

---

<div class="post-metadata">

### Author: ![Aaqu](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/aaqu/32/101407_2.png) [@Aaqu](https://discourse.nodered.org/u/Aaqu)
#### Post date: [15 April 2026 18:20 UTC](https://discourse.nodered.org/t/project-in-node-red-for-code-nodes-store-code-in-files/100765/5 "2026-04-15T18:20:50Z")

</div>

> [@stoivo](#):
>
> How did you create the screenshot? Which tool is this

6 prmts to claude code max built me ​​a tool for editing flow json

---

<div class="post-metadata">

### Author: ![stoivo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/stoivo/32/106669_2.png) [@stoivo](https://discourse.nodered.org/u/stoivo)
#### Post date: [16 April 2026 06:37 UTC](https://discourse.nodered.org/t/project-in-node-red-for-code-nodes-store-code-in-files/100765/6 "2026-04-16T06:37:51Z")

</div>

> [@Aaqu](#):
>
> 6 prmts to claude code max built me ​​a tool for editing flow json

It is also a tool to edit flow.json. I think that this is the way to go. Too bad projects in node red don't help with this (and is almost useless).

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [15 July 2026 06:37 UTC](https://discourse.nodered.org/t/project-in-node-red-for-code-nodes-store-code-in-files/100765/7 "2026-07-15T06:37:54Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
